@graphcommerce/googlerecaptcha 2.0.1 → 2.0.4

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/CHANGELOG.md CHANGED
@@ -1,57 +1,78 @@
1
1
  # Change Log
2
2
 
3
+ ## 2.0.4
4
+
5
+ ### Patch Changes
6
+
7
+ - [#1307](https://github.com/ho-nl/m2-pwa/pull/1307) [`bd10506d3`](https://github.com/ho-nl/m2-pwa/commit/bd10506d32fdbc91d01dadc29a12ebd1e0943655) Thanks [@paales](https://github.com/paales)! - All default exports are now named exports internally and all `index.tsx` are renamed to the component name.
8
+
9
+ * [#1307](https://github.com/ho-nl/m2-pwa/pull/1307) [`27cb1f2d8`](https://github.com/ho-nl/m2-pwa/commit/27cb1f2d8dbfb8f1b301ce56fb6a2b6c1fc6a5ef) Thanks [@paales](https://github.com/paales)! - upgrade dependencies
10
+
11
+ * Updated dependencies [[`bd10506d3`](https://github.com/ho-nl/m2-pwa/commit/bd10506d32fdbc91d01dadc29a12ebd1e0943655), [`27cb1f2d8`](https://github.com/ho-nl/m2-pwa/commit/27cb1f2d8dbfb8f1b301ce56fb6a2b6c1fc6a5ef)]:
12
+ - @graphcommerce/graphql@3.0.4
13
+
14
+ ## 2.0.3
15
+
16
+ ### Patch Changes
17
+
18
+ - [`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96) Thanks [@paales](https://github.com/paales)! - made packages public
19
+
20
+ - Updated dependencies [[`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96)]:
21
+ - @graphcommerce/graphql@3.0.3
22
+
23
+ ## 2.0.2
24
+
25
+ ### Patch Changes
26
+
27
+ - [#1276](https://github.com/ho-nl/m2-pwa/pull/1276) [`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2) Thanks [@paales](https://github.com/paales)! - We've moved lots of internal packages from `dependencies` to `peerDependencies`. The result of this is that there will be significantly less duplicate packages in the node_modules folders.
28
+
29
+ * [#1276](https://github.com/ho-nl/m2-pwa/pull/1276) [`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d) Thanks [@paales](https://github.com/paales)! - Upgraded to [NextJS 12.1](https://nextjs.org/blog/next-12-1)! This is just for compatibility, but we'll be implementing [On-demand Incremental Static Regeneration](https://nextjs.org/blog/next-12-1#on-demand-incremental-static-regeneration-beta) soon.
30
+
31
+ This will greatly reduce the requirement to rebuid stuff and we'll add a management UI on the frontend to be able to revalidate pages manually.
32
+
33
+ * Updated dependencies [[`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2), [`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d)]:
34
+ - @graphcommerce/graphql@3.0.2
35
+
3
36
  ## 2.0.1
4
37
 
5
38
  ### Patch Changes
6
39
 
7
- - [`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)
8
- Thanks [@paales](https://github.com/paales)! - Added homepage and repository package.json files,
9
- so that the packages link to back to the website and repository
10
- - Updated dependencies
11
- [[`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)]:
40
+ - [`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514) Thanks [@paales](https://github.com/paales)! - Added homepage and repository package.json files, so that the packages link to back to the website and repository
41
+ - Updated dependencies [[`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)]:
12
42
  - @graphcommerce/graphql@3.0.1
13
43
 
14
44
  ## 2.0.0
15
45
 
16
46
  ### Major Changes
17
47
 
18
- - [#1258](https://github.com/ho-nl/m2-pwa/pull/1258)
19
- [`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)
20
- Thanks [@paales](https://github.com/paales)! - Upgraded to Material UI 5
48
+ - [#1258](https://github.com/ho-nl/m2-pwa/pull/1258) [`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05) Thanks [@paales](https://github.com/paales)! - Upgraded to Material UI 5
21
49
 
22
50
  ### Patch Changes
23
51
 
24
- - Updated dependencies
25
- [[`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)]:
52
+ - Updated dependencies [[`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)]:
26
53
  - @graphcommerce/graphql@3.0.0
27
54
 
28
- All notable changes to this project will be documented in this file. See
29
- [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
55
+ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
30
56
 
31
57
  ## [1.1.8](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/googlerecaptcha@1.1.7...@graphcommerce/googlerecaptcha@1.1.8) (2021-12-20)
32
58
 
33
59
  ### Bug Fixes
34
60
 
35
- - make sure we're not loading gogole properties when keys are not given
36
- ([8636715](https://github.com/ho-nl/m2-pwa/commit/8636715d61985e0919208ffb64354c3ebb43ed01))
61
+ - make sure we're not loading gogole properties when keys are not given ([8636715](https://github.com/ho-nl/m2-pwa/commit/8636715d61985e0919208ffb64354c3ebb43ed01))
37
62
 
38
63
  ## [1.1.2](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/googlerecaptcha@1.1.1...@graphcommerce/googlerecaptcha@1.1.2) (2021-11-12)
39
64
 
40
65
  ### Bug Fixes
41
66
 
42
- - remove fragment
43
- ([3d8a964](https://github.com/ho-nl/m2-pwa/commit/3d8a964f3009f04b3ba09d54272a31b592e7a052))
44
- - remove hiding recaptcha from themeProvider, add to component
45
- ([6a49f77](https://github.com/ho-nl/m2-pwa/commit/6a49f77ef9fd22ea66e7acd1322c65ac6426fd3b))
67
+ - remove fragment ([3d8a964](https://github.com/ho-nl/m2-pwa/commit/3d8a964f3009f04b3ba09d54272a31b592e7a052))
68
+ - remove hiding recaptcha from themeProvider, add to component ([6a49f77](https://github.com/ho-nl/m2-pwa/commit/6a49f77ef9fd22ea66e7acd1322c65ac6426fd3b))
46
69
 
47
70
  # 1.1.0 (2021-11-03)
48
71
 
49
72
  ### Bug Fixes
50
73
 
51
- - make sure we're not throwing a warning on the production env.
52
- ([7ee4499](https://github.com/ho-nl/m2-pwa/commit/7ee449959509a13e684c19e2ff707e378d6b5c35))
74
+ - make sure we're not throwing a warning on the production env. ([7ee4499](https://github.com/ho-nl/m2-pwa/commit/7ee449959509a13e684c19e2ff707e378d6b5c35))
53
75
 
54
76
  ### Features
55
77
 
56
- - google recaptcha v3 integration
57
- ([a9fcc16](https://github.com/ho-nl/m2-pwa/commit/a9fcc16f93951e61378c99a2e183e2d754da1d50))
78
+ - google recaptcha v3 integration ([a9fcc16](https://github.com/ho-nl/m2-pwa/commit/a9fcc16f93951e61378c99a2e183e2d754da1d50))
@@ -1,7 +1,7 @@
1
1
  import Script from 'next/script'
2
2
  import React from 'react'
3
3
 
4
- export default function GoogleRecaptchaV3Script() {
4
+ export function GoogleRecaptchaV3Script() {
5
5
  const siteKey = process.env.NEXT_PUBLIC_GOOGLE_RECAPTCHA_V3_SITE_KEY
6
6
 
7
7
  if (process.env.NODE_ENV !== 'production' && !siteKey)
package/index.ts CHANGED
@@ -1,2 +1,2 @@
1
- export { default as GoogleRecaptchaV3Script } from './components/GoogleRecaptchaV3Script'
1
+ export * from './components/GoogleRecaptchaV3Script'
2
2
  export * from './link/recaptchaLink'
@@ -11,7 +11,9 @@ export const recaptchaLink = setContext(async (operation, context) => {
11
11
  const recaptchaKey = process.env.NEXT_PUBLIC_GOOGLE_RECAPTCHA_V3_SITE_KEY
12
12
  if (!recaptchaKey || !globalThis.grecaptcha || !isMutation(operation)) return context
13
13
 
14
- await new Promise<void>(globalThis.grecaptcha?.ready)
14
+ await new Promise<void>((resolve) => {
15
+ globalThis.grecaptcha?.ready(resolve)
16
+ })
15
17
 
16
18
  const token = await globalThis.grecaptcha.execute(recaptchaKey, { action: 'submit' })
17
19
 
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/googlerecaptcha",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "2.0.1",
5
+ "version": "2.0.4",
6
6
  "sideEffects": false,
7
7
  "prettier": "@graphcommerce/prettier-config-pwa",
8
8
  "eslintConfig": {
@@ -12,15 +12,16 @@
12
12
  }
13
13
  },
14
14
  "devDependencies": {
15
- "@graphcommerce/eslint-config-pwa": "^4.0.1",
16
- "@graphcommerce/prettier-config-pwa": "^4.0.1",
17
- "@graphcommerce/typescript-config-pwa": "^4.0.1",
18
- "@playwright/test": "^1.18.1",
15
+ "@graphcommerce/eslint-config-pwa": "^4.0.5",
16
+ "@graphcommerce/prettier-config-pwa": "^4.0.3",
17
+ "@graphcommerce/typescript-config-pwa": "^4.0.2",
18
+ "@playwright/test": "^1.19.2",
19
19
  "@types/grecaptcha": "^3.0.3"
20
20
  },
21
21
  "dependencies": {
22
- "@graphcommerce/graphql": "^3.0.1",
23
- "@mui/material": "^5.4.1",
22
+ "@graphcommerce/graphql": "^3.0.4"
23
+ },
24
+ "peerDependencies": {
24
25
  "next": "^12.0.10",
25
26
  "react": "^17.0.2",
26
27
  "react-dom": "^17.0.2"