@apollo/client 3.12.9 → 3.12.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # @apollo/client
2
2
 
3
+ ## 3.12.11
4
+
5
+ ### Patch Changes
6
+
7
+ - [#12351](https://github.com/apollographql/apollo-client/pull/12351) [`3da908b`](https://github.com/apollographql/apollo-client/commit/3da908b1dde73847805a41c287a83700b2b88887) Thanks [@jerelmiller](https://github.com/jerelmiller)! - Fixes an issue where the wrong `networkStatus` and `loading` value was emitted from `observableQuery` when calling `fetchMore` with a `no-cache` fetch policy. The `networkStatus` now properly reports as `ready` and `loading` as `false` after the result is returned.
8
+
9
+ - [#12354](https://github.com/apollographql/apollo-client/pull/12354) [`a24ef94`](https://github.com/apollographql/apollo-client/commit/a24ef9474f8f7a864f8b866563f8f7e661d2533f) Thanks [@phryneas](https://github.com/phryneas)! - Fix missing `main.d.cts` file
10
+
11
+ ## 3.12.10
12
+
13
+ ### Patch Changes
14
+
15
+ - [#12341](https://github.com/apollographql/apollo-client/pull/12341) [`f2bb0b9`](https://github.com/apollographql/apollo-client/commit/f2bb0b9955564e432345ee8bd431290e698d092c) Thanks [@phryneas](https://github.com/phryneas)! - `useReadQuery`/`useQueryRefHandlers`: Fix a "hook order" warning that might be emitted in React 19 dev mode.
16
+
17
+ - [#12342](https://github.com/apollographql/apollo-client/pull/12342) [`219b26b`](https://github.com/apollographql/apollo-client/commit/219b26ba5a697981ad700e05b926d42db0fb8e59) Thanks [@phryneas](https://github.com/phryneas)! - Add `graphql-ws` `^6.0.3` as a valid `peerDependency`
18
+
3
19
  ## 3.12.9
4
20
 
5
21
  ### Patch Changes
package/apollo-client.cjs CHANGED
@@ -31,7 +31,7 @@ function _interopNamespace(e) {
31
31
  var equal__default = /*#__PURE__*/_interopDefaultLegacy(equal);
32
32
  var React__namespace = /*#__PURE__*/_interopNamespace(React);
33
33
 
34
- var version = "3.12.9";
34
+ var version = "3.12.11";
35
35
 
36
36
  function maybe(thunk) {
37
37
  try {
@@ -5433,7 +5433,7 @@ var ObservableQuery = (function (_super) {
5433
5433
  fetchMoreResult: fetchMoreResult.data,
5434
5434
  variables: combinedOptions.variables,
5435
5435
  });
5436
- _this.reportResult(tslib.__assign(tslib.__assign({}, lastResult), { data: data }), _this.variables);
5436
+ _this.reportResult(tslib.__assign(tslib.__assign({}, lastResult), { networkStatus: originalNetworkStatus, loading: isNetworkRequestInFlight(originalNetworkStatus), data: data }), _this.variables);
5437
5437
  }
5438
5438
  return _this.maskResult(fetchMoreResult);
5439
5439
  })
@@ -9156,9 +9156,11 @@ function useLoadableQuery(query, options) {
9156
9156
 
9157
9157
  function useQueryRefHandlers(queryRef) {
9158
9158
  var unwrapped = unwrapQueryRef(queryRef);
9159
- return wrapHook("useQueryRefHandlers", useQueryRefHandlers_, unwrapped ?
9159
+ var clientOrObsQuery = useApolloClient(unwrapped ?
9160
9160
  unwrapped["observable"]
9161
- : useApolloClient())(queryRef);
9161
+ : undefined);
9162
+ return wrapHook("useQueryRefHandlers",
9163
+ useQueryRefHandlers_, clientOrObsQuery)(queryRef);
9162
9164
  }
9163
9165
  function useQueryRefHandlers_(queryRef) {
9164
9166
  assertWrappedQueryRef(queryRef);
@@ -9191,9 +9193,11 @@ function useQueryRefHandlers_(queryRef) {
9191
9193
 
9192
9194
  function useReadQuery(queryRef) {
9193
9195
  var unwrapped = unwrapQueryRef(queryRef);
9194
- return wrapHook("useReadQuery", useReadQuery_, unwrapped ?
9196
+ var clientOrObsQuery = useApolloClient(unwrapped ?
9195
9197
  unwrapped["observable"]
9196
- : useApolloClient())(queryRef);
9198
+ : undefined);
9199
+ return wrapHook("useReadQuery",
9200
+ useReadQuery_, clientOrObsQuery)(queryRef);
9197
9201
  }
9198
9202
  function useReadQuery_(queryRef) {
9199
9203
  assertWrappedQueryRef(queryRef);