@graphcommerce/graphql 9.0.4-canary.1 → 9.0.4-canary.10

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,5 +1,27 @@
1
1
  # Change Log
2
2
 
3
+ ## 9.0.4-canary.10
4
+
5
+ ## 9.0.4-canary.9
6
+
7
+ ## 9.0.4-canary.8
8
+
9
+ ## 9.0.4-canary.7
10
+
11
+ ## 9.0.4-canary.6
12
+
13
+ ## 9.0.4-canary.5
14
+
15
+ ## 9.0.4-canary.4
16
+
17
+ ## 9.0.4-canary.3
18
+
19
+ ### Patch Changes
20
+
21
+ - [#2477](https://github.com/graphcommerce-org/graphcommerce/pull/2477) [`8015eab`](https://github.com/graphcommerce-org/graphcommerce/commit/8015eabc130dacf1f2703980cd5f0ad2c550aa4d) - Upgraded to @apollo/client 3.12.3 without impacting typescript compilation performance. ([@paales](https://github.com/paales))
22
+
23
+ ## 9.0.4-canary.2
24
+
3
25
  ## 9.0.4-canary.1
4
26
 
5
27
  ## 9.0.4-canary.0
package/apollo.ts CHANGED
@@ -7,3 +7,9 @@ export * from '@apollo/client/link/error'
7
7
  export * from '@apollo/client/utilities'
8
8
 
9
9
  export { getOperationName } from '@apollo/client/utilities'
10
+
11
+ declare module '@apollo/client' {
12
+ interface DataMasking {
13
+ enabled: true
14
+ }
15
+ }
@@ -4,7 +4,7 @@ import { useIsSSR } from '@graphcommerce/next-ui/hooks/useIsSsr'
4
4
  // eslint-disable-next-line import/no-extraneous-dependencies
5
5
  import { getCssFlag, removeCssFlag, setCssFlag } from '@graphcommerce/next-ui/utils/cssFlags'
6
6
  import { useContext, useEffect } from 'react'
7
- import type { QueryHookOptions, QueryResult, TypedDocumentNode } from '../apollo'
7
+ import type { MaybeMasked, QueryHookOptions, QueryResult, TypedDocumentNode } from '../apollo'
8
8
  import { useQuery } from '../apollo'
9
9
  import { PrivateQueryMaskContext } from '../components/PrivateQueryMask/PrivateQueryMask'
10
10
  import { usePrivateQueryContext } from './usePrivateQueryContext'
@@ -32,7 +32,7 @@ export function usePrivateQuery<
32
32
  document: TypedDocumentNode<Q, V>,
33
33
  options: QueryHookOptions<Q, V>,
34
34
  unscopedResult: Q,
35
- ): Omit<QueryResult<Q, V>, 'data'> & { data: Q; mask: boolean } {
35
+ ): Omit<QueryResult<Q, V>, 'data'> & { data: Q | NonNullable<MaybeMasked<Q>>; mask: boolean } {
36
36
  const { skip = true } = options
37
37
  const context = usePrivateQueryContext()
38
38
  const isSsr = useIsSSR()
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/graphql",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "9.0.4-canary.1",
5
+ "version": "9.0.4-canary.10",
6
6
  "sideEffects": false,
7
7
  "main": "index.ts",
8
8
  "prettier": "@graphcommerce/prettier-config-pwa",
@@ -13,7 +13,7 @@
13
13
  }
14
14
  },
15
15
  "dependencies": {
16
- "@apollo/client": "3.11.10",
16
+ "@apollo/client": "~3.12.3",
17
17
  "@graphql-codegen/add": "5.0.3",
18
18
  "@graphql-codegen/fragment-matcher": "5.0.2",
19
19
  "@graphql-codegen/introspection": "4.0.3",
@@ -27,11 +27,11 @@
27
27
  "graphql": "^16.10.0"
28
28
  },
29
29
  "peerDependencies": {
30
- "@graphcommerce/eslint-config-pwa": "^9.0.4-canary.1",
31
- "@graphcommerce/graphql-codegen-near-operation-file": "9.0.4-canary.1",
32
- "@graphcommerce/graphql-codegen-relay-optimizer-plugin": "9.0.4-canary.1",
33
- "@graphcommerce/prettier-config-pwa": "^9.0.4-canary.1",
34
- "@graphcommerce/typescript-config-pwa": "^9.0.4-canary.1",
30
+ "@graphcommerce/eslint-config-pwa": "^9.0.4-canary.10",
31
+ "@graphcommerce/graphql-codegen-near-operation-file": "9.0.4-canary.10",
32
+ "@graphcommerce/graphql-codegen-relay-optimizer-plugin": "9.0.4-canary.10",
33
+ "@graphcommerce/prettier-config-pwa": "^9.0.4-canary.10",
34
+ "@graphcommerce/typescript-config-pwa": "^9.0.4-canary.10",
35
35
  "@graphql-mesh/plugin-http-details-extensions": "*",
36
36
  "react": "^18.2.0",
37
37
  "react-dom": "^18.2.0"