diff --git a/package.json b/package.json
index 22db653035..22cdc2529b 100755
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/pwa-studio",
- "version": "14.0.1",
+ "version": "14.1.0",
"private": true,
"workspaces": [
"packages/babel-preset-peregrine",
diff --git a/packages/create-pwa/package.json b/packages/create-pwa/package.json
index ca4c18505a..b8a9169921 100644
--- a/packages/create-pwa/package.json
+++ b/packages/create-pwa/package.json
@@ -30,7 +30,7 @@
"homepage": "https://github.com/magento/pwa-studio/tree/main/packages/create-pwa#readme",
"dependencies": {
"@magento/pwa-buildpack": "~11.5.3",
- "@magento/venia-concept": "~14.0.1",
+ "@magento/venia-concept": "~14.1.0",
"chalk": "^2.4.2",
"change-case": "^3.1.0",
"compression": "~1.7.4",
diff --git a/packages/extensions/experience-platform-connector/package.json b/packages/extensions/experience-platform-connector/package.json
index 34aca9b833..d384b9a2c5 100644
--- a/packages/extensions/experience-platform-connector/package.json
+++ b/packages/extensions/experience-platform-connector/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/experience-platform-connector",
- "version": "1.0.7",
+ "version": "1.0.8",
"publishConfig": {
"access": "public"
},
@@ -18,7 +18,7 @@
"devDependencies": {},
"peerDependencies": {
"@apollo/client": "~3.5.0",
- "@magento/peregrine": "~14.3.1",
+ "@magento/peregrine": "~14.4.1",
"@magento/pwa-buildpack": "~11.5.3",
"react": "~17.0.1"
},
diff --git a/packages/extensions/upward-security-headers/package.json b/packages/extensions/upward-security-headers/package.json
index 2affa89f27..3ee3e4be31 100644
--- a/packages/extensions/upward-security-headers/package.json
+++ b/packages/extensions/upward-security-headers/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/upward-security-headers",
- "version": "1.0.16",
+ "version": "1.0.17",
"publishConfig": {
"access": "public"
},
@@ -14,7 +14,7 @@
"license": "(OSL-3.0 OR AFL-3.0)",
"peerDependencies": {
"@magento/pwa-buildpack": "~11.5.3",
- "@magento/venia-ui": "~11.4.0",
+ "@magento/venia-ui": "~11.5.0",
"webpack": "~4.46.0"
},
"pwa-studio": {
diff --git a/packages/extensions/venia-sample-eventing/package.json b/packages/extensions/venia-sample-eventing/package.json
index 9771eac8d1..985db76f0f 100644
--- a/packages/extensions/venia-sample-eventing/package.json
+++ b/packages/extensions/venia-sample-eventing/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/venia-sample-eventing",
- "version": "0.0.8",
+ "version": "0.0.9",
"publishConfig": {
"access": "public"
},
@@ -12,7 +12,7 @@
"repository": "github:magento/pwa-studio",
"license": "(OSL-3.0 OR AFL-3.0)",
"peerDependencies": {
- "@magento/peregrine": "~14.3.1",
+ "@magento/peregrine": "~14.4.1",
"@magento/pwa-buildpack": "~11.5.3",
"react": "~17.0.1"
},
diff --git a/packages/extensions/venia-sample-language-packs/package.json b/packages/extensions/venia-sample-language-packs/package.json
index 9a762956ca..73c3a70ff5 100644
--- a/packages/extensions/venia-sample-language-packs/package.json
+++ b/packages/extensions/venia-sample-language-packs/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/venia-sample-language-packs",
- "version": "0.0.16",
+ "version": "0.0.17",
"publishConfig": {
"access": "public"
},
@@ -13,7 +13,7 @@
"license": "(OSL-3.0 OR AFL-3.0)",
"peerDependencies": {
"@magento/pwa-buildpack": "~11.5.3",
- "@magento/venia-ui": "~11.4.0"
+ "@magento/venia-ui": "~11.5.0"
},
"pwa-studio": {
"targets": {
diff --git a/packages/extensions/venia-sample-payments-checkmo/package.json b/packages/extensions/venia-sample-payments-checkmo/package.json
index b3271ff7ad..4c7d8cf74c 100644
--- a/packages/extensions/venia-sample-payments-checkmo/package.json
+++ b/packages/extensions/venia-sample-payments-checkmo/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/venia-sample-payments-checkmo",
- "version": "0.0.14",
+ "version": "0.0.15",
"publishConfig": {
"access": "public"
},
@@ -12,9 +12,9 @@
"repository": "github:magento/pwa-studio",
"license": "(OSL-3.0 OR AFL-3.0)",
"peerDependencies": {
- "@magento/peregrine": "~14.3.1",
+ "@magento/peregrine": "~14.4.1",
"@magento/pwa-buildpack": "~11.5.3",
- "@magento/venia-ui": "~11.4.0",
+ "@magento/venia-ui": "~11.5.0",
"react": "~17.0.1",
"react-intl": "~5.20.0",
"react-router-dom": "~5.2.0"
diff --git a/packages/pagebuilder/package.json b/packages/pagebuilder/package.json
index f4ed562eb2..645e457e23 100644
--- a/packages/pagebuilder/package.json
+++ b/packages/pagebuilder/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/pagebuilder",
- "version": "9.3.1",
+ "version": "9.3.2",
"publishConfig": {
"access": "public"
},
@@ -34,9 +34,9 @@
"homepage": "https://github.com/magento/pwa-studio/tree/main/packages/pagebuilder#readme",
"dependencies": {},
"devDependencies": {
- "@magento/peregrine": "~14.3.1",
+ "@magento/peregrine": "~14.4.1",
"@magento/pwa-buildpack": "~11.5.3",
- "@magento/venia-ui": "~11.4.0",
+ "@magento/venia-ui": "~11.5.0",
"@storybook/react": "~6.3.7",
"jarallax": "~1.11.1",
"load-google-maps-api": "~2.0.1",
@@ -50,9 +50,9 @@
"peerDependencies": {
"@apollo/client": "~3.5.0",
"@magento/babel-preset-peregrine": "~1.3.3",
- "@magento/peregrine": "~14.3.1",
+ "@magento/peregrine": "~14.4.1",
"@magento/pwa-buildpack": "~11.5.3",
- "@magento/venia-ui": "~11.4.0",
+ "@magento/venia-ui": "~11.5.0",
"jarallax": "~1.11.1",
"load-google-maps-api": "~2.0.1",
"lodash.escape": "~4.0.1",
diff --git a/packages/peregrine/lib/store/actions/user/asyncActions.js b/packages/peregrine/lib/store/actions/user/asyncActions.js
index d3a2ccdb25..353187d66c 100755
--- a/packages/peregrine/lib/store/actions/user/asyncActions.js
+++ b/packages/peregrine/lib/store/actions/user/asyncActions.js
@@ -63,13 +63,17 @@ export const resetPassword = ({ email }) =>
dispatch(actions.resetPassword.receive());
};
-export const setToken = (token, customer_token_lifetime = 3600) =>
+export const setToken = (token, customerAccessTokenLifetime = 1) =>
async function thunk(...args) {
const [dispatch] = args;
// Store token in local storage.
// TODO: Get correct token expire time from API
- storage.setItem('signin_token', token, customer_token_lifetime);
+ storage.setItem(
+ 'signin_token',
+ token,
+ customerAccessTokenLifetime * 3600
+ );
// Persist in store
dispatch(actions.setToken(token));
diff --git a/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/__tests__/__snapshots__/useCreateAccount.spec.js.snap b/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/__tests__/__snapshots__/useCreateAccount.spec.js.snap
index 59d4c64a3f..f19ad85d20 100644
--- a/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/__tests__/__snapshots__/useCreateAccount.spec.js.snap
+++ b/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/__tests__/__snapshots__/useCreateAccount.spec.js.snap
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
-exports[`handle submit event creates an account, dispatches event, signs in, and generates a new cart 1`] = `
+exports[`handle submit event should dispatch create account event 1`] = `
Object {
"payload": Object {
"email": "bender@planet.express",
@@ -12,42 +12,24 @@ Object {
}
`;
-exports[`returns the correct shape 1`] = `
+exports[`should return properly 1`] = `
Object {
"errors": Map {
- "createAccountQuery" => undefined,
- "signInMutation" => undefined,
+ "createAccountQuery" => null,
+ "signInMutation" => null,
},
"handleEnterKeyPress": [Function],
"handleSubmit": [Function],
"initialValues": Object {
"customer": Object {
- "email": "philipfry@fake.email",
- "firstname": "Philip",
- "lastname": "Fry",
- },
- },
- "isDisabled": false,
- "recaptchaWidgetProps": Object {},
-}
-`;
-
-exports[`returns the correct shape with no initial values 1`] = `
-Object {
- "errors": Map {
- "createAccountQuery" => undefined,
- "signInMutation" => undefined,
- },
- "handleEnterKeyPress": [Function],
- "handleSubmit": [Function],
- "initialValues": Object {
- "customer": Object {
- "email": undefined,
- "firstname": undefined,
- "lastname": undefined,
+ "email": "gooston@goosemail.com",
+ "firstname": "Gooseton",
+ "lastname": "Jr",
},
+ "userName": "gooseton",
},
"isDisabled": false,
+ "minimumPasswordLength": 8,
"recaptchaWidgetProps": Object {},
}
`;
diff --git a/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/__tests__/useCreateAccount.spec.js b/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/__tests__/useCreateAccount.spec.js
index f84bbc00a8..5389309839 100644
--- a/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/__tests__/useCreateAccount.spec.js
+++ b/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/__tests__/useCreateAccount.spec.js
@@ -1,248 +1,338 @@
import React from 'react';
-import { MockedProvider } from '@apollo/client/testing';
-import { renderHook, act } from '@testing-library/react-hooks';
+import { useMutation, useQuery, useApolloClient } from '@apollo/client';
+import { act } from 'react-test-renderer';
-import { useUserContext } from '../../../../context/user';
-import { useCartContext } from '../../../../context/cart';
+import { useCartContext } from '../../../../../lib/context/cart';
+import { useUserContext } from '../../../../../lib/context/user';
import { useAwaitQuery } from '../../../../hooks/useAwaitQuery';
-
+import createTestInstance from '../../../../util/createTestInstance';
import { useCreateAccount } from '../useCreateAccount';
-import defaultOperations from '../createAccount.gql';
import { useEventingContext } from '../../../../context/eventing';
+jest.mock('@apollo/client', () => {
+ const apolloClient = jest.requireActual('@apollo/client');
+
+ return {
+ ...apolloClient,
+ useMutation: jest.fn().mockReturnValue([jest.fn()]),
+ useApolloClient: jest.fn(),
+ useQuery: jest.fn()
+ };
+});
+jest.mock('../../../../hooks/useAwaitQuery', () => ({
+ useAwaitQuery: jest.fn().mockReturnValue(jest.fn())
+}));
+jest.mock('../../../../../lib/context/user', () => ({
+ useUserContext: jest
+ .fn()
+ .mockReturnValue([
+ { isGettingDetails: false },
+ { getUserDetails: jest.fn(), setToken: jest.fn() }
+ ])
+}));
+jest.mock('../../../../../lib/context/cart', () => ({
+ useCartContext: jest.fn().mockReturnValue([
+ { cartId: '1234' },
+ {
+ createCart: jest.fn(),
+ removeCart: jest.fn(),
+ getCartDetails: jest.fn()
+ }
+ ])
+}));
+jest.mock('../../../../store/actions/cart', () => {
+ const cartActions = jest.requireActual(
+ '../../../store/actions/cart/actions'
+ );
+ const retrieveCartId = jest.fn().mockReturnValue('12345');
-const createAccountVariables = {
- email: 'bender@planet.express',
- firstname: 'Bender',
- lastname: 'Rodriguez',
- password: '123456',
- is_subscribed: false
-};
-const createAccount = jest.fn();
-const createAccountMock = {
- request: {
- query: defaultOperations.createAccountMutation,
- variables: createAccountVariables
- },
- result: () => {
- createAccount();
+ return Object.assign(cartActions, {
+ retrieveCartId
+ });
+});
- return {
- data: {
- id: 'user_id'
- }
- };
- }
-};
+jest.mock('../../../../hooks/useGoogleReCaptcha', () => ({
+ useGoogleReCaptcha: jest.fn().mockReturnValue({
+ recaptchaLoading: false,
+ generateReCaptchaData: jest.fn(() => {}),
+ recaptchaWidgetProps: {}
+ })
+}));
-const createCartMock = {
- request: {
- query: defaultOperations.createCartMutation
- },
- result: {
- data: {
- cartId: '1234'
- }
- }
+jest.mock('@magento/peregrine/lib/context/eventing', () => ({
+ useEventingContext: jest.fn().mockReturnValue([{}, { dispatch: jest.fn() }])
+}));
+
+const Component = props => {
+ const talonProps = useCreateAccount(props);
+
+ return ;
};
-const getCartDetailsMock = {
- request: {
- query: defaultOperations.getCartDetailsQuery,
- variables: {
- cartId: '1234'
- }
- },
- result: {
- data: {
- id: '1234'
- }
- }
+const getTalonProps = props => {
+ const tree = createTestInstance();
+ const { root } = tree;
+ const { talonProps } = root.findByType('i').props;
+
+ const update = newProps => {
+ act(() => {
+ tree.update();
+ });
+
+ return root.findByType('i').props.talonProps;
+ };
+
+ return { talonProps, tree, update };
};
-const getCustomerMock = {
- request: {
- query: defaultOperations.getCustomerQuery
- },
- result: {
- data: {
- customer: {
- id: '123'
- }
+const getCustomerQuery = 'getCustomerQuery';
+const getCartDetailsQuery = 'getCartDetailsQuery';
+const createAccountMutation = 'createAccountMutation';
+const createCartMutation = 'createCartMutation';
+const signInMutation = 'signInMutation';
+const mergeCartsMutation = 'mergeCartsMutation';
+const getStoreConfigQuery = 'getStoreConfigQuery';
+
+const getStoreConfigQueryFn = jest.fn().mockReturnValue({
+ data: {
+ storeConfig: {
+ store_code: 'default',
+ minimum_password_length: 8,
+ customer_access_token_lifetime: 1
}
}
-};
-
-const signInVariables = {
- email: 'bender@planet.express',
- password: '123456'
-};
-const authToken = 'auth-token-123';
-const customerTokenLifetime = 3600;
-const signInMock = {
- request: {
- query: defaultOperations.signInMutation,
- variables: signInVariables
- },
- result: {
+});
+const customerQueryFn = jest.fn();
+const getCartDetailsQueryFn = jest.fn();
+const createAccountMutationFn = jest
+ .fn()
+ .mockReturnValue([jest.fn(), { error: null }]);
+const createCartMutationFn = jest.fn().mockReturnValue([jest.fn()]);
+const signInMutationFn = jest.fn().mockReturnValue([
+ jest.fn().mockReturnValue({
data: {
generateCustomerToken: {
- token: authToken,
- customer_token_lifetime: customerTokenLifetime
+ token: 'customer token'
}
}
- }
+ }),
+ { error: null }
+]);
+const mergeCartsMutationFn = jest.fn().mockReturnValue([jest.fn()]);
+const clearCacheData = jest.fn();
+const client = { clearCacheData };
+
+const defaultProps = {
+ operations: {
+ createAccountMutation,
+ createCartMutation,
+ getCartDetailsQuery,
+ getCustomerQuery,
+ mergeCartsMutation,
+ getStoreConfigQuery,
+ signInMutation
+ },
+ initialValues: {
+ email: 'gooston@goosemail.com',
+ firstName: 'Gooseton',
+ lastName: 'Jr',
+ userName: 'gooseton'
+ },
+ onSubmit: jest.fn(),
+ onCancel: jest.fn()
};
-jest.mock('../../../../context/user');
-const mockGetUserDetails = jest.fn();
-const mockSetToken = jest.fn();
-useUserContext.mockImplementation(() => {
- const data = {
- isGettingDetails: false
- };
+const defaultFormValues = {
+ customer: {
+ email: 'bender@planet.express',
+ firstname: 'Bender',
+ lastname: 'Rodriguez'
+ },
+ password: '123456',
+ subscribe: false
+};
+beforeAll(() => {
+ useQuery.mockImplementation(query => {
+ if (query === getStoreConfigQuery) {
+ return getStoreConfigQueryFn();
+ } else {
+ return [jest.fn(), {}];
+ }
+ });
+ useAwaitQuery.mockImplementation(query => {
+ if (query === getCustomerQuery) {
+ return customerQueryFn();
+ } else if (query === getCartDetailsQuery) {
+ return getCartDetailsQueryFn();
+ } else {
+ return jest.fn();
+ }
+ });
- const api = {
- getUserDetails: mockGetUserDetails,
- setToken: mockSetToken
- };
+ useMutation.mockImplementation(mutation => {
+ if (mutation === createAccountMutation) {
+ return createAccountMutationFn();
+ } else if (mutation === createCartMutation) {
+ return createCartMutationFn();
+ } else if (mutation === signInMutation) {
+ return signInMutationFn();
+ } else if (mutation === mergeCartsMutation) {
+ return mergeCartsMutationFn();
+ } else {
+ return [jest.fn()];
+ }
+ });
- return [data, api];
+ useApolloClient.mockReturnValue(client);
});
+test('should return properly', () => {
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
-jest.mock('../../../../context/cart');
-const mockCreateCart = jest.fn();
-const mockGetCartDetails = jest.fn();
-const mockRemoveCart = jest.fn();
-useCartContext.mockImplementation(() => {
- const data = {};
- const api = {
- createCart: mockCreateCart,
- getCartDetails: mockGetCartDetails,
- removeCart: mockRemoveCart
- };
-
- return [data, api];
+ expect(talonProps).toMatchSnapshot();
});
-jest.mock('../../../../hooks/useAwaitQuery');
-useAwaitQuery.mockImplementation(jest.fn());
+// test('returns the correct shape with no initial values', async() => {
+// const onSubmit = jest.fn();
+// const { talonProps } = getTalonProps({
+// ...defaultProps,
+// onSubmit: handleSubmit
+// });
+// // await talonProps.handleSubmit()
+// expect(talonProps).toMatchSnapshot();
+// });
-jest.mock('../../../../hooks/useGoogleReCaptcha', () => ({
- useGoogleReCaptcha: jest.fn().mockReturnValue({
- recaptchaLoading: false,
- generateReCaptchaData: jest.fn(() => {}),
- recaptchaWidgetProps: {}
- })
-}));
+describe('handle submit event', () => {
+ it('should create a new account', async () => {
+ const createAccount = jest.fn().mockResolvedValueOnce(true);
+ createAccountMutationFn.mockReturnValueOnce([
+ createAccount,
+ { error: null }
+ ]);
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
-const handleSubmit = jest.fn();
+ await talonProps.handleSubmit(defaultFormValues);
-const initialProps = {
- initialValues: {
- email: 'philipfry@fake.email',
- firstName: 'Philip',
- lastName: 'Fry'
- },
- onSubmit: handleSubmit
-};
+ expect(createAccount).toHaveBeenCalledWith({
+ variables: {
+ email: defaultFormValues.customer.email,
+ firstname: defaultFormValues.customer.firstname,
+ lastname: defaultFormValues.customer.lastname,
+ password: defaultFormValues.password,
+ is_subscribed: !!defaultFormValues.subscribe
+ }
+ });
+ });
+ it('should dispatch create account event', async () => {
+ const mockDispatch = jest.fn();
-jest.mock('@magento/peregrine/lib/context/eventing', () => ({
- useEventingContext: jest.fn().mockReturnValue([{}, { dispatch: jest.fn() }])
-}));
+ useEventingContext.mockReturnValueOnce([
+ {},
+ {
+ dispatch: mockDispatch
+ }
+ ]);
-const renderHookWithProviders = ({
- renderHookOptions = { initialProps },
- mocks = [
- createAccountMock,
- signInMock,
- createCartMock,
- getCartDetailsMock,
- getCustomerMock
- ]
-} = {}) => {
- const wrapper = ({ children }) => (
-
- {children}
-
- );
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
- return renderHook(useCreateAccount, { wrapper, ...renderHookOptions });
-};
+ await talonProps.handleSubmit(defaultFormValues);
-test('returns the correct shape', () => {
- const { result } = renderHookWithProviders();
+ expect(mockDispatch).toHaveBeenCalledTimes(1);
+ expect(mockDispatch.mock.calls[0][0]).toMatchSnapshot();
+ });
+ test('should signin after account creation', async () => {
+ const token = 'customertoken';
+ const customer_token_lifetime = 1;
+ const signIn = jest.fn().mockReturnValue({
+ data: {
+ generateCustomerToken: {
+ token
+ }
+ }
+ });
+ signInMutationFn.mockReturnValueOnce([signIn, { error: null }]);
+ const setToken = jest.fn();
+ useUserContext.mockReturnValueOnce([
+ { isGettingDetails: false },
+ { getUserDetails: jest.fn(), setToken }
+ ]);
+
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
- expect(result.current).toMatchSnapshot();
-});
+ await talonProps.handleSubmit(defaultFormValues);
-test('returns the correct shape with no initial values', () => {
- const { result } = renderHookWithProviders({
- renderHookOptions: {
- initialProps: {
- onSubmit: handleSubmit
+ expect(signIn).toHaveBeenCalledWith({
+ variables: {
+ email: defaultFormValues.customer.email,
+ password: defaultFormValues.password
}
- }
+ });
+ expect(setToken).toHaveBeenCalledWith(token, customer_token_lifetime);
});
- expect(result.current).toMatchSnapshot();
-});
+ it('should create a new cart', async () => {
+ const createCart = jest.fn();
+ useCartContext.mockReturnValueOnce([
+ { cartId: '1234' },
+ {
+ createCart,
+ removeCart: jest.fn(),
+ getCartDetails: jest.fn()
+ }
+ ]);
-describe('handle submit event', () => {
- const formValues = {
- customer: {
- email: 'bender@planet.express',
- firstname: 'Bender',
- lastname: 'Rodriguez'
- },
- password: '123456',
- subscribe: false
- };
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
- it('creates an account, dispatches event, signs in, and generates a new cart', async () => {
- const [, { dispatch }] = useEventingContext();
+ await talonProps.handleSubmit(defaultFormValues);
- const { result } = renderHookWithProviders();
+ expect(createCart).toHaveBeenCalled();
+ });
- await act(async () => {
- await result.current.handleSubmit(formValues);
- });
+ it('should remove cart', async () => {
+ const removeCart = jest.fn();
+ useCartContext.mockReturnValueOnce([
+ { cartId: '1234' },
+ {
+ createCart: jest.fn(),
+ removeCart,
+ getCartDetails: jest.fn()
+ }
+ ]);
- expect(mockSetToken).toHaveBeenCalledWith('auth-token-123', 3600);
- expect(createAccount).toHaveBeenCalled();
- expect(mockRemoveCart).toHaveBeenCalled();
- expect(mockCreateCart).toHaveBeenCalledWith({
- fetchCartId: expect.anything()
+ const { talonProps } = getTalonProps({
+ ...defaultProps
});
- expect(mockGetUserDetails).toHaveBeenCalled();
- expect(mockGetCartDetails).toHaveBeenCalled();
- expect(handleSubmit).toHaveBeenCalledTimes(1);
- expect(result.current.isDisabled).toBeTruthy();
+ await talonProps.handleSubmit(defaultFormValues);
- expect(dispatch).toHaveBeenCalledTimes(1);
- expect(dispatch.mock.calls[0][0]).toMatchSnapshot();
+ expect(removeCart).toHaveBeenCalled();
});
- it('does not call the submit callback if it is not defined', async () => {
- const { result } = renderHookWithProviders({
- renderHookOptions: {
- initialProps: {
- onSubmit: undefined
- }
- }
- });
+ it('should call onSubmit', async () => {
+ const onSubmit = jest.fn();
- await act(async () => {
- await result.current.handleSubmit(formValues);
+ const { talonProps } = getTalonProps({
+ ...defaultProps,
+ onSubmit
});
- expect(handleSubmit).not.toHaveBeenCalled();
+ await talonProps.handleSubmit(defaultFormValues);
+
+ expect(onSubmit).toHaveBeenCalled();
});
it('resets the submitting state on error', async () => {
const consoleErrorSpy = jest.spyOn(console, 'error');
-
+ const mockGetUserDetails = jest.fn();
useUserContext.mockImplementationOnce(() => {
return [
{
@@ -256,20 +346,20 @@ describe('handle submit event', () => {
}
];
});
- const { result } = renderHookWithProviders();
-
- await act(async () => {
- await result.current.handleSubmit(formValues);
+ const { talonProps, update } = getTalonProps({
+ ...defaultProps
});
+ const { isDisabled } = update;
+ await talonProps.handleSubmit(defaultFormValues);
expect(consoleErrorSpy).toHaveBeenCalled();
- expect(result.current.isDisabled).toBeFalsy();
+ expect(isDisabled).toBeFalsy();
});
it('does not log errors to console in production when an error happens', async () => {
const consoleErrorSpy = jest.spyOn(console, 'error');
process.env.NODE_ENV = 'production';
-
+ const mockGetUserDetails = jest.fn();
useUserContext.mockImplementationOnce(() => {
return [
{
@@ -283,12 +373,10 @@ describe('handle submit event', () => {
}
];
});
- const { result } = renderHookWithProviders();
-
+ const { talonProps } = getTalonProps(defaultProps);
await act(async () => {
- await result.current.handleSubmit(formValues);
+ await talonProps.handleSubmit();
});
-
expect(consoleErrorSpy).not.toHaveBeenCalled();
});
});
diff --git a/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/createAccount.gql.js b/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/createAccount.gql.js
index 6787d4682f..730eb08a89 100644
--- a/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/createAccount.gql.js
+++ b/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/createAccount.gql.js
@@ -1,4 +1,5 @@
import { gql } from '@apollo/client';
+import { GET_STORE_CONFIG_DATA } from '../../CreateAccount/createAccount.gql';
export const CREATE_ACCOUNT = gql`
mutation CreateAccountAfterCheckout(
@@ -44,7 +45,6 @@ export const SIGN_IN = gql`
mutation SignInAfterCheckout($email: String!, $password: String!) {
generateCustomerToken(email: $email, password: $password) {
token
- customer_token_lifetime
}
}
`;
@@ -111,5 +111,6 @@ export default {
createCartMutation: CREATE_CART,
getCartDetailsQuery: GET_CART_DETAILS,
getCustomerQuery: GET_CUSTOMER,
- signInMutation: SIGN_IN
+ signInMutation: SIGN_IN,
+ getStoreConfigQuery: GET_STORE_CONFIG_DATA
};
diff --git a/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/useCreateAccount.js b/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/useCreateAccount.js
index ef3a6d6169..b9176afb3f 100644
--- a/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/useCreateAccount.js
+++ b/packages/peregrine/lib/talons/CheckoutPage/OrderConfirmationPage/useCreateAccount.js
@@ -1,5 +1,5 @@
import { useCallback, useMemo, useState } from 'react';
-import { useMutation } from '@apollo/client';
+import { useMutation, useQuery } from '@apollo/client';
import mergeOperations from '../../../util/shallowMerge';
import { useUserContext } from '../../../context/user';
@@ -39,7 +39,8 @@ export const useCreateAccount = props => {
createCartMutation,
getCartDetailsQuery,
getCustomerQuery,
- signInMutation
+ signInMutation,
+ getStoreConfigQuery
} = operations;
const [isSubmitting, setIsSubmitting] = useState(false);
const [, { createCart, getCartDetails, removeCart }] = useCartContext();
@@ -65,6 +66,23 @@ export const useCreateAccount = props => {
fetchPolicy: 'no-cache'
});
+ const { data: storeConfigData } = useQuery(getStoreConfigQuery, {
+ fetchPolicy: 'cache-and-network',
+ nextFetchPolicy: 'cache-first'
+ });
+
+ const {
+ minimumPasswordLength,
+ customerAccessTokenLifetime
+ } = useMemo(() => {
+ const storeConfig = storeConfigData?.storeConfig || {};
+
+ return {
+ minimumPasswordLength: storeConfig.minimum_password_length,
+ customerAccessTokenLifetime:
+ storeConfig.customer_access_token_lifetime
+ };
+ }, [storeConfigData]);
const fetchUserDetails = useAwaitQuery(getCustomerQuery);
const fetchCartDetails = useAwaitQuery(getCartDetailsQuery);
@@ -117,12 +135,8 @@ export const useCreateAccount = props => {
...recaptchaDataForSignIn
});
const token = signInResponse.data.generateCustomerToken.token;
- const customerTokenLifetime =
- signInResponse.data.generateCustomerToken
- .customer_token_lifetime;
-
- await (customerTokenLifetime
- ? setToken(token, customerTokenLifetime)
+ await (customerAccessTokenLifetime
+ ? setToken(token, customerAccessTokenLifetime)
: setToken(token));
// Clear guest cart from redux.
@@ -152,6 +166,7 @@ export const useCreateAccount = props => {
}
},
[
+ customerAccessTokenLifetime,
createAccount,
createCart,
fetchCartDetails,
@@ -200,6 +215,7 @@ export const useCreateAccount = props => {
handleEnterKeyPress,
isDisabled: isSubmitting || isGettingDetails || recaptchaLoading,
initialValues: sanitizedInitialValues,
- recaptchaWidgetProps
+ recaptchaWidgetProps,
+ minimumPasswordLength
};
};
diff --git a/packages/peregrine/lib/talons/CreateAccount/__tests__/__snapshots__/useCreateAccount.spec.js.snap b/packages/peregrine/lib/talons/CreateAccount/__tests__/__snapshots__/useCreateAccount.spec.js.snap
index 47c2adbc08..7553782a17 100644
--- a/packages/peregrine/lib/talons/CreateAccount/__tests__/__snapshots__/useCreateAccount.spec.js.snap
+++ b/packages/peregrine/lib/talons/CreateAccount/__tests__/__snapshots__/useCreateAccount.spec.js.snap
@@ -37,6 +37,7 @@ Object {
"userName": "gooseton",
},
"isDisabled": false,
+ "minimumPasswordLength": 8,
"recaptchaWidgetProps": Object {},
}
`;
diff --git a/packages/peregrine/lib/talons/CreateAccount/__tests__/useCreateAccount.spec.js b/packages/peregrine/lib/talons/CreateAccount/__tests__/useCreateAccount.spec.js
index 01dbabe7a7..6c22e62abe 100644
--- a/packages/peregrine/lib/talons/CreateAccount/__tests__/useCreateAccount.spec.js
+++ b/packages/peregrine/lib/talons/CreateAccount/__tests__/useCreateAccount.spec.js
@@ -1,5 +1,5 @@
import React from 'react';
-import { useMutation, useApolloClient } from '@apollo/client';
+import { useMutation, useQuery, useApolloClient } from '@apollo/client';
import { act } from 'react-test-renderer';
import { useCartContext } from '../../../context/cart';
@@ -16,7 +16,8 @@ jest.mock('@apollo/client', () => {
return {
...apolloClient,
useMutation: jest.fn().mockReturnValue([jest.fn()]),
- useApolloClient: jest.fn()
+ useApolloClient: jest.fn(),
+ useQuery: jest.fn()
};
});
jest.mock('../../../../lib/hooks/useAwaitQuery', () => ({
@@ -91,7 +92,17 @@ const createAccountMutation = 'createAccountMutation';
const createCartMutation = 'createCartMutation';
const signInMutation = 'signInMutation';
const mergeCartsMutation = 'mergeCartsMutation';
-
+const getStoreConfigQuery = 'getStoreConfigQuery';
+
+const getStoreConfigQueryFn = jest.fn().mockReturnValue({
+ data: {
+ storeConfig: {
+ store_code: 'default',
+ minimum_password_length: 8,
+ customer_access_token_lifetime: 1
+ }
+ }
+});
const customerQueryFn = jest.fn();
const getCartDetailsQueryFn = jest.fn();
const createAccountMutationFn = jest
@@ -102,8 +113,7 @@ const signInMutationFn = jest.fn().mockReturnValue([
jest.fn().mockReturnValue({
data: {
generateCustomerToken: {
- token: 'customer token',
- customer_token_lifetime: 3600
+ token: 'customer token'
}
}
}),
@@ -120,6 +130,7 @@ const defaultProps = {
getCartDetailsQuery,
getCustomerQuery,
mergeCartsMutation,
+ getStoreConfigQuery,
signInMutation
},
initialValues: {
@@ -143,6 +154,13 @@ const defaultFormValues = {
};
beforeAll(() => {
+ useQuery.mockImplementation(query => {
+ if (query === getStoreConfigQuery) {
+ return getStoreConfigQueryFn();
+ } else {
+ return [jest.fn(), {}];
+ }
+ });
useAwaitQuery.mockImplementation(query => {
if (query === getCustomerQuery) {
return customerQueryFn();
@@ -273,12 +291,11 @@ describe('handleSubmit', () => {
test('should signin after account creation', async () => {
const token = 'customertoken';
- const customer_token_lifetime = 3600;
+ const customer_token_lifetime = 1;
const signIn = jest.fn().mockReturnValue({
data: {
generateCustomerToken: {
- token,
- customer_token_lifetime
+ token
}
}
});
diff --git a/packages/peregrine/lib/talons/CreateAccount/createAccount.gql.js b/packages/peregrine/lib/talons/CreateAccount/createAccount.gql.js
index 4eed9375f0..0400d0e0e4 100644
--- a/packages/peregrine/lib/talons/CreateAccount/createAccount.gql.js
+++ b/packages/peregrine/lib/talons/CreateAccount/createAccount.gql.js
@@ -45,7 +45,6 @@ export const SIGN_IN = gql`
mutation SignInAfterCreate($email: String!, $password: String!) {
generateCustomerToken(email: $email, password: $password) {
token
- customer_token_lifetime
}
}
`;
@@ -126,6 +125,16 @@ export const MERGE_CARTS = gql`
}
${CheckoutPageFragment}
`;
+export const GET_STORE_CONFIG_DATA = gql`
+ query GetStoreConfigData {
+ # eslint-disable-next-line @graphql-eslint/require-id-when-available
+ storeConfig {
+ store_code
+ minimum_password_length
+ customer_access_token_lifetime
+ }
+ }
+`;
export default {
createAccountMutation: CREATE_ACCOUNT,
@@ -133,5 +142,6 @@ export default {
getCartDetailsQuery: GET_CART_DETAILS,
getCustomerQuery: GET_CUSTOMER,
mergeCartsMutation: MERGE_CARTS,
- signInMutation: SIGN_IN
+ signInMutation: SIGN_IN,
+ getStoreConfigQuery: GET_STORE_CONFIG_DATA
};
diff --git a/packages/peregrine/lib/talons/CreateAccount/useCreateAccount.js b/packages/peregrine/lib/talons/CreateAccount/useCreateAccount.js
index 5bfca3e6bc..68922ca694 100644
--- a/packages/peregrine/lib/talons/CreateAccount/useCreateAccount.js
+++ b/packages/peregrine/lib/talons/CreateAccount/useCreateAccount.js
@@ -1,5 +1,5 @@
import { useCallback, useMemo, useState } from 'react';
-import { useApolloClient, useMutation } from '@apollo/client';
+import { useApolloClient, useMutation, useQuery } from '@apollo/client';
import mergeOperations from '../../util/shallowMerge';
import { useUserContext } from '../../context/user';
@@ -37,7 +37,8 @@ export const useCreateAccount = props => {
getCartDetailsQuery,
getCustomerQuery,
mergeCartsMutation,
- signInMutation
+ signInMutation,
+ getStoreConfigQuery
} = operations;
const apolloClient = useApolloClient();
const [isSubmitting, setIsSubmitting] = useState(false);
@@ -69,6 +70,24 @@ export const useCreateAccount = props => {
fetchPolicy: 'no-cache'
});
+ const { data: storeConfigData } = useQuery(getStoreConfigQuery, {
+ fetchPolicy: 'cache-and-network',
+ nextFetchPolicy: 'cache-first'
+ });
+
+ const {
+ minimumPasswordLength,
+ customerAccessTokenLifetime
+ } = useMemo(() => {
+ const storeConfig = storeConfigData?.storeConfig || {};
+
+ return {
+ minimumPasswordLength: storeConfig.minimum_password_length,
+ customerAccessTokenLifetime:
+ storeConfig.customer_access_token_lifetime
+ };
+ }, [storeConfigData]);
+
const fetchUserDetails = useAwaitQuery(getCustomerQuery);
const fetchCartDetails = useAwaitQuery(getCartDetailsQuery);
@@ -136,11 +155,8 @@ export const useCreateAccount = props => {
...recaptchaDataForSignIn
});
const token = signInResponse.data.generateCustomerToken.token;
- const customerTokenLifetime =
- signInResponse.data.generateCustomerToken
- .customer_token_lifetime;
- await (customerTokenLifetime
- ? setToken(token, customerTokenLifetime)
+ await (customerAccessTokenLifetime
+ ? setToken(token, customerAccessTokenLifetime)
: setToken(token));
// Clear all cart/customer data from cache and redux.
await apolloClient.clearCacheData(apolloClient, 'cart');
@@ -181,6 +197,7 @@ export const useCreateAccount = props => {
},
[
+ customerAccessTokenLifetime,
cartId,
generateReCaptchaData,
createAccount,
@@ -225,7 +242,8 @@ export const useCreateAccount = props => {
handleCancelKeyPress,
initialValues: sanitizedInitialValues,
isDisabled: isSubmitting || isGettingDetails || recaptchaLoading,
- recaptchaWidgetProps
+ recaptchaWidgetProps,
+ minimumPasswordLength
};
};
@@ -239,6 +257,7 @@ export const useCreateAccount = props => {
*
* @property {GraphQLAST} customerQuery query to fetch customer details
* @property {GraphQLAST} getCartDetailsQuery query to get cart details
+ * @property {GraphQLAST} getStoreConfigQuery query to get store config
*/
/**
diff --git a/packages/peregrine/lib/talons/SignIn/__tests__/__snapshots__/useSignIn.spec.js.snap b/packages/peregrine/lib/talons/SignIn/__tests__/__snapshots__/useSignIn.spec.js.snap
new file mode 100644
index 0000000000..fff8f0d9a3
--- /dev/null
+++ b/packages/peregrine/lib/talons/SignIn/__tests__/__snapshots__/useSignIn.spec.js.snap
@@ -0,0 +1,75 @@
+// Jest Snapshot v1, https://goo.gl/fbAQLP
+
+exports[`mutation error is returned by talon 1`] = `
+Map {
+ "getUserDetailsQuery" => "getDetails error from redux",
+ "signInMutation" => "Sign In Mutation Error",
+}
+`;
+
+exports[`returns correct shape 1`] = `
+Object {
+ "cartContext": Array [
+ Object {
+ "cartId": "1234",
+ },
+ Object {
+ "createCart": [MockFunction],
+ "getCartDetails": [MockFunction],
+ "removeCart": [MockFunction],
+ },
+ ],
+ "errors": Map {
+ "getUserDetailsQuery" => "getDetails error from redux",
+ "signInMutation" => null,
+ },
+ "eventingContext": Array [
+ Object {},
+ Object {
+ "dispatch": [MockFunction],
+ },
+ ],
+ "fetchCartDetails": [MockFunction],
+ "fetchCartId": [MockFunction],
+ "fetchUserDetails": undefined,
+ "forgotPasswordHandleEnterKeyPress": [Function],
+ "googleReCaptcha": Object {
+ "generateReCaptchaData": [Function],
+ "recaptchaLoading": undefined,
+ "recaptchaWidgetProps": Object {
+ "containerElement": [Function],
+ "shouldRender": false,
+ },
+ },
+ "handleCreateAccount": [Function],
+ "handleEnterKeyPress": [Function],
+ "handleForgotPassword": [Function],
+ "handleSubmit": [Function],
+ "isBusy": undefined,
+ "isSigningIn": false,
+ "mergeCarts": [MockFunction],
+ "recaptchaWidgetProps": Object {
+ "containerElement": [Function],
+ "shouldRender": false,
+ },
+ "setFormApi": [Function],
+ "setIsSigningIn": [Function],
+ "signInMutationResult": Array [
+ [MockFunction],
+ Object {
+ "error": null,
+ },
+ ],
+ "signinHandleEnterKeyPress": [Function],
+ "userContext": Array [
+ Object {
+ "getDetailsError": "getDetails error from redux",
+ "isGettingDetails": false,
+ },
+ Object {
+ "getUserDetails": [MockFunction],
+ "setToken": [MockFunction],
+ },
+ ],
+}
+`;
diff --git a/packages/peregrine/lib/talons/SignIn/__tests__/useSignIn.spec.js b/packages/peregrine/lib/talons/SignIn/__tests__/useSignIn.spec.js
index 9f3ed201bb..42845b790a 100644
--- a/packages/peregrine/lib/talons/SignIn/__tests__/useSignIn.spec.js
+++ b/packages/peregrine/lib/talons/SignIn/__tests__/useSignIn.spec.js
@@ -1,19 +1,17 @@
import React from 'react';
-import { useApolloClient } from '@apollo/client';
-import { MockedProvider } from '@apollo/client/testing';
-import { renderHook, act } from '@testing-library/react-hooks';
-
-import { useCartContext } from '../../../context/cart';
+import { useApolloClient, useQuery, useMutation } from '@apollo/client';
+import { act } from '@testing-library/react-hooks';
+import createTestInstance from '../../../util/createTestInstance';
import { useUserContext } from '../../../context/user';
-import defaultOperations from '../signIn.gql';
import { useSignIn } from '../useSignIn';
-import { useEventingContext } from '../../../context/eventing';
import { useAwaitQuery } from '../../../hooks/useAwaitQuery';
jest.mock('@apollo/client', () => {
return {
...jest.requireActual('@apollo/client'),
- useApolloClient: jest.fn()
+ useApolloClient: jest.fn(),
+ useMutation: jest.fn().mockReturnValue([jest.fn()]),
+ useQuery: jest.fn()
};
});
jest.mock('../../../hooks/useAwaitQuery', () => ({
@@ -23,9 +21,9 @@ jest.mock('../../../store/actions/cart', () => ({
retrieveCartId: jest.fn().mockReturnValue('new-cart-id')
}));
-jest.mock('../../../context/cart', () => ({
+jest.mock('../../../../lib/context/cart', () => ({
useCartContext: jest.fn().mockReturnValue([
- { cartId: 'old-cart-id' },
+ { cartId: '1234' },
{
createCart: jest.fn(),
removeCart: jest.fn(),
@@ -34,7 +32,7 @@ jest.mock('../../../context/cart', () => ({
])
}));
-jest.mock('../../../context/user', () => ({
+jest.mock('../../../../lib/context/user', () => ({
useUserContext: jest.fn().mockReturnValue([
{
isGettingDetails: false,
@@ -43,7 +41,6 @@ jest.mock('../../../context/user', () => ({
{ getUserDetails: jest.fn(), setToken: jest.fn() }
])
}));
-
jest.mock('../../../hooks/useGoogleReCaptcha', () => ({
useGoogleReCaptcha: jest.fn().mockReturnValue({
recaptchaLoading: false,
@@ -56,43 +53,71 @@ jest.mock('@magento/peregrine/lib/context/eventing', () => ({
useEventingContext: jest.fn().mockReturnValue([{}, { dispatch: jest.fn() }])
}));
+const Component = props => {
+ const talonProps = useSignIn(props);
+
+ return ;
+};
+
+const getTalonProps = props => {
+ const tree = createTestInstance();
+ const { root } = tree;
+ const { talonProps } = root.findByType('i').props;
+
+ const update = newProps => {
+ act(() => {
+ tree.update();
+ });
+
+ return root.findByType('i').props.talonProps;
+ };
+
+ return { talonProps, tree, update };
+};
+
const signInVariables = {
email: 'fry@planetexpress.com',
password: 'slurm is the best'
};
-const authToken = 'auth-token-123';
-const customerTokenLifetime = 3600;
-const signInMock = {
- request: {
- query: defaultOperations.signInMutation,
- variables: signInVariables
- },
- result: {
+const getCartDetailsQuery = 'getCartDetailsQuery';
+const getCustomerQuery = 'getCustomerQuery';
+const createCartMutation = 'createCartMutation';
+const signInMutation = 'signInMutation';
+const mergeCartsMutation = 'mergeCartsMutation';
+const getStoreConfigQuery = 'getStoreConfigQuery';
+
+const getCartDetailsQueryFn = jest.fn();
+const customerQueryFn = jest.fn();
+const mergeCartsMutationFn = jest.fn().mockReturnValue([jest.fn()]);
+const getStoreConfigQueryFn = jest.fn().mockReturnValue({
+ data: {
+ storeConfig: {
+ store_code: 'default',
+ customer_access_token_lifetime: 1
+ }
+ }
+});
+const signInMutationFn = jest.fn().mockReturnValue([
+ jest.fn().mockReturnValue({
data: {
generateCustomerToken: {
- token: authToken,
- customer_token_lifetime: customerTokenLifetime
+ token: 'customer token'
}
}
- }
-};
-
-const mergeCartsMock = {
- request: {
- query: defaultOperations.mergeCartsMutation,
- variables: {
- destinationCartId: 'new-cart-id',
- sourceCartId: 'old-cart-id'
- }
+ }),
+ { error: null }
+]);
+
+const defaultProps = {
+ operations: {
+ createCartMutation,
+ getCustomerQuery,
+ mergeCartsMutation,
+ signInMutation,
+ getStoreConfigQuery
},
- result: {
- data: null
- }
-};
-
-const initialProps = {
- getCartDetailsQuery: 'getCartDetailsQuery',
+ getCartDetailsQuery: jest.fn(),
setDefaultUsername: jest.fn(),
showCreateAccount: jest.fn(),
showForgotPassword: jest.fn(),
@@ -102,7312 +127,160 @@ const initialProps = {
const clearCacheData = jest.fn();
const client = { clearCacheData };
-const renderHookWithProviders = ({
- renderHookOptions = { initialProps },
- mocks = [signInMock, mergeCartsMock]
-} = {}) => {
- const wrapper = ({ children }) => (
-
- {children}
-
- );
-
- return renderHook(useSignIn, { wrapper, ...renderHookOptions });
-};
-
beforeEach(() => {
+ useQuery.mockImplementation(query => {
+ if (query === getStoreConfigQuery) {
+ return getStoreConfigQueryFn();
+ } else {
+ return [jest.fn(), {}];
+ }
+ });
+ useAwaitQuery.mockImplementation(query => {
+ if (query === getCustomerQuery) {
+ return customerQueryFn();
+ } else if (query === getCartDetailsQuery) {
+ return getCartDetailsQueryFn();
+ } else {
+ return jest.fn();
+ }
+ });
+ useMutation.mockImplementation(mutation => {
+ if (mutation === signInMutation) {
+ return signInMutationFn();
+ } else if (mutation === mergeCartsMutation) {
+ return mergeCartsMutationFn();
+ } else {
+ return [jest.fn()];
+ }
+ });
useApolloClient.mockReturnValue(client);
});
test('returns correct shape', () => {
- const { result } = renderHookWithProviders();
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
- expect(result.current).toMatchInlineSnapshot(`
- Object {
- "cartContext": Array [
- Object {
- "cartId": "old-cart-id",
- },
- Object {
- "createCart": [MockFunction],
- "getCartDetails": [MockFunction],
- "removeCart": [MockFunction],
- },
- ],
- "errors": Map {
- "getUserDetailsQuery" => "getDetails error from redux",
- "signInMutation" => undefined,
- },
- "eventingContext": Array [
- Object {},
- Object {
- "dispatch": [MockFunction],
- },
- ],
- "fetchCartDetails": undefined,
- "fetchCartId": [Function],
- "fetchUserDetails": undefined,
- "forgotPasswordHandleEnterKeyPress": [Function],
- "googleReCaptcha": Object {
- "generateReCaptchaData": [Function],
- "recaptchaLoading": true,
- "recaptchaWidgetProps": Object {
- "containerElement": [Function],
- "shouldRender": false,
- },
- },
- "handleCreateAccount": [Function],
- "handleEnterKeyPress": [Function],
- "handleForgotPassword": [Function],
- "handleSubmit": [Function],
- "isBusy": true,
- "isSigningIn": false,
- "mergeCarts": [Function],
- "recaptchaWidgetProps": Object {
- "containerElement": [Function],
- "shouldRender": false,
- },
- "setFormApi": [Function],
- "setIsSigningIn": [Function],
- "signInMutationResult": Array [
- [Function],
- Object {
- "called": false,
- "client": ApolloClient {
- "cache": InMemoryCache {
- "addTypename": false,
- "config": Object {
- "addTypename": false,
- "canonizeResults": false,
- "dataIdFromObject": [Function],
- "resultCaching": true,
- },
- "data": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": [Circular],
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "toReference": [Function],
- },
- "evict": [Function],
- "getFragmentDoc": [Function],
- "makeVar": [Function],
- "maybeBroadcastWatch": [Function],
- "modify": [Function],
- "optimisticData": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": [Circular],
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "reset": [Function],
- "storeReader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- "storeWriter": StoreWriter {
- "cache": [Circular],
- "reader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- },
- "txCount": 0,
- "typenameDocumentCache": Map {},
- "watches": Set {
- Object {
- "callback": [Function],
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- "watcher": QueryInfo {
- "cache": [Circular],
- "cancel": [Function],
- "dirty": false,
- "document": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "graphQLErrors": Array [],
- "lastDiff": Object {
- "diff": Object {
- "complete": false,
- "missing": Array [
- MissingFieldError {
- "message": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- "path": Object {
- "recaptchaV3Config": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- },
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- ],
- "result": Object {},
- },
- "options": Object {
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- },
- },
- "lastRequestId": 1,
- "lastWatch": [Circular],
- "listeners": Set {
- [Function],
- },
- "networkError": null,
- "networkStatus": 1,
- "observableQuery": ObservableQuery {
- "_subscriber": [Function],
- "concast": Concast {
- "_subscriber": [Function],
- "addCount": 1,
- "cancel": [Function],
- "handlers": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- Object {
- "error": [Function],
- "next": [Function],
- },
- },
- "promise": Promise {},
- "reject": [Function],
- "resolve": [Function],
- "sources": Array [],
- "sub": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- "initialFetchPolicy": "cache-and-network",
- "isTornDown": false,
- "last": Object {
- "result": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- "variables": Object {},
- },
- "observer": Object {
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- SubscriptionObserver {
- "_subscription": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": undefined,
- "error": [Function],
- "next": [Function],
- },
- "_queue": Array [
- Object {
- "type": "next",
- "value": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- },
- ],
- "_state": "buffering",
- },
- },
- },
- "options": Object {
- "fetchPolicy": "cache-and-network",
- "notifyOnNetworkStatusChange": false,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- "queryId": "1",
- "queryInfo": [Circular],
- "queryManager": QueryManager {
- "assumeImmutableResults": false,
- "cache": [Circular],
- "clientAwareness": Object {
- "name": undefined,
- "version": undefined,
- },
- "fetchCancelFns": Map {
- "1" => [Function],
- },
- "inFlightLinkObservables": Map {
- Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- } => Map {
- "{}" => Concast {
- "_subscriber": [Function],
- "addCount": 1,
- "cancel": [Function],
- "handlers": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- SubscriptionObserver {
- "_subscription": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- },
- "promise": Promise {},
- "reject": [Function],
- "resolve": [Function],
- "sources": Array [],
- "sub": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- },
- },
- "link": MockLink {
- "addTypename": false,
- "mockedResponsesByKey": Object {
- "{\\"query\\":\\"mutation MergeCartsAfterSignIn($sourceCartId: String!, $destinationCartId: String!) {\\\\n mergeCarts(\\\\n source_cart_id: $sourceCartId\\\\n destination_cart_id: $destinationCartId\\\\n ) {\\\\n id\\\\n items {\\\\n uid\\\\n }\\\\n ...CheckoutPageFragment\\\\n }\\\\n}\\\\n\\\\nfragment CheckoutPageFragment on Cart {\\\\n id\\\\n items {\\\\n uid\\\\n product {\\\\n uid\\\\n stock_status\\\\n }\\\\n }\\\\n total_quantity\\\\n available_payment_methods {\\\\n code\\\\n }\\\\n}\\\\n\\"}": Array [
- Object {
- "request": Object {
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "MergeCartsAfterSignIn",
- },
- "operation": "mutation",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "source_cart_id",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "sourceCartId",
- },
- },
- },
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "destination_cart_id",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "destinationCartId",
- },
- },
- },
- ],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "mergeCarts",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "id",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "items",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- Object {
- "directives": Array [],
- "kind": "FragmentSpread",
- "name": Object {
- "kind": "Name",
- "value": "CheckoutPageFragment",
- },
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "sourceCartId",
- },
- },
- },
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "destinationCartId",
- },
- },
- },
- ],
- },
- Object {
- "directives": Array [],
- "kind": "FragmentDefinition",
- "name": Object {
- "kind": "Name",
- "value": "CheckoutPageFragment",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "id",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "items",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "product",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "stock_status",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "total_quantity",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "available_payment_methods",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "code",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "typeCondition": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "Cart",
- },
- },
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 932,
- "start": 0,
- },
- },
- "variables": Object {
- "destinationCartId": "new-cart-id",
- "sourceCartId": "old-cart-id",
- },
- },
- "result": Object {
- "data": null,
- },
- },
- ],
- "{\\"query\\":\\"mutation SignIn($email: String!, $password: String!) {\\\\n generateCustomerToken(email: $email, password: $password) {\\\\n token\\\\n customer_token_lifetime\\\\n }\\\\n}\\\\n\\"}": Array [
- Object {
- "request": Object {
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "SignIn",
- },
- "operation": "mutation",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- },
- },
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- },
- },
- ],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "generateCustomerToken",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "token",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "customer_token_lifetime",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- },
- },
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- },
- },
- ],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 198,
- "start": 0,
- },
- },
- "variables": Object {
- "email": "fry@planetexpress.com",
- "password": "slurm is the best",
- },
- },
- "result": Object {
- "data": Object {
- "generateCustomerToken": Object {
- "customer_token_lifetime": 3600,
- "token": "auth-token-123",
- },
- },
- },
- },
- ],
- },
- "operation": Object {
- "extensions": Object {},
- "operationName": "GetReCaptchaV3Config",
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- },
- "localState": LocalState {
- "cache": [Circular],
- "client": [Circular],
- },
- "mutationIdCounter": 1,
- "mutationStore": Object {},
- "onBroadcast": [Function],
- "queries": Map {
- "1" => [Circular],
- },
- "queryDeduplication": true,
- "queryIdCounter": 2,
- "requestIdCounter": 2,
- "ssrMode": false,
- "transformCache": WeakMap {},
- },
- "queryName": "GetReCaptchaV3Config",
- "subscriptions": Set {},
- },
- "oqListener": [Function],
- "queryId": "1",
- "stopped": false,
- "subscriptions": Set {},
- "variables": Object {},
- },
- },
- },
- },
- "clearStoreCallbacks": Array [],
- "defaultOptions": Object {},
- "disableNetworkFetches": false,
- "link": MockLink {
- "addTypename": false,
- "mockedResponsesByKey": Object {
- "{\\"query\\":\\"mutation MergeCartsAfterSignIn($sourceCartId: String!, $destinationCartId: String!) {\\\\n mergeCarts(\\\\n source_cart_id: $sourceCartId\\\\n destination_cart_id: $destinationCartId\\\\n ) {\\\\n id\\\\n items {\\\\n uid\\\\n }\\\\n ...CheckoutPageFragment\\\\n }\\\\n}\\\\n\\\\nfragment CheckoutPageFragment on Cart {\\\\n id\\\\n items {\\\\n uid\\\\n product {\\\\n uid\\\\n stock_status\\\\n }\\\\n }\\\\n total_quantity\\\\n available_payment_methods {\\\\n code\\\\n }\\\\n}\\\\n\\"}": Array [
- Object {
- "request": Object {
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "MergeCartsAfterSignIn",
- },
- "operation": "mutation",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "source_cart_id",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "sourceCartId",
- },
- },
- },
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "destination_cart_id",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "destinationCartId",
- },
- },
- },
- ],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "mergeCarts",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "id",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "items",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- Object {
- "directives": Array [],
- "kind": "FragmentSpread",
- "name": Object {
- "kind": "Name",
- "value": "CheckoutPageFragment",
- },
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "sourceCartId",
- },
- },
- },
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "destinationCartId",
- },
- },
- },
- ],
- },
- Object {
- "directives": Array [],
- "kind": "FragmentDefinition",
- "name": Object {
- "kind": "Name",
- "value": "CheckoutPageFragment",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "id",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "items",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "product",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "stock_status",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "total_quantity",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "available_payment_methods",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "code",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "typeCondition": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "Cart",
- },
- },
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 932,
- "start": 0,
- },
- },
- "variables": Object {
- "destinationCartId": "new-cart-id",
- "sourceCartId": "old-cart-id",
- },
- },
- "result": Object {
- "data": null,
- },
- },
- ],
- "{\\"query\\":\\"mutation SignIn($email: String!, $password: String!) {\\\\n generateCustomerToken(email: $email, password: $password) {\\\\n token\\\\n customer_token_lifetime\\\\n }\\\\n}\\\\n\\"}": Array [
- Object {
- "request": Object {
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "SignIn",
- },
- "operation": "mutation",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- },
- },
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- },
- },
- ],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "generateCustomerToken",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "token",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "customer_token_lifetime",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- },
- },
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- },
- },
- ],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 198,
- "start": 0,
- },
- },
- "variables": Object {
- "email": "fry@planetexpress.com",
- "password": "slurm is the best",
- },
- },
- "result": Object {
- "data": Object {
- "generateCustomerToken": Object {
- "customer_token_lifetime": 3600,
- "token": "auth-token-123",
- },
- },
- },
- },
- ],
- },
- "operation": Object {
- "extensions": Object {},
- "operationName": "GetReCaptchaV3Config",
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- },
- "localState": LocalState {
- "cache": InMemoryCache {
- "addTypename": false,
- "config": Object {
- "addTypename": false,
- "canonizeResults": false,
- "dataIdFromObject": [Function],
- "resultCaching": true,
- },
- "data": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": [Circular],
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "toReference": [Function],
- },
- "evict": [Function],
- "getFragmentDoc": [Function],
- "makeVar": [Function],
- "maybeBroadcastWatch": [Function],
- "modify": [Function],
- "optimisticData": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": [Circular],
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "reset": [Function],
- "storeReader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- "storeWriter": StoreWriter {
- "cache": [Circular],
- "reader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- },
- "txCount": 0,
- "typenameDocumentCache": Map {},
- "watches": Set {
- Object {
- "callback": [Function],
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- "watcher": QueryInfo {
- "cache": [Circular],
- "cancel": [Function],
- "dirty": false,
- "document": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "graphQLErrors": Array [],
- "lastDiff": Object {
- "diff": Object {
- "complete": false,
- "missing": Array [
- MissingFieldError {
- "message": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- "path": Object {
- "recaptchaV3Config": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- },
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- ],
- "result": Object {},
- },
- "options": Object {
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- },
- },
- "lastRequestId": 1,
- "lastWatch": [Circular],
- "listeners": Set {
- [Function],
- },
- "networkError": null,
- "networkStatus": 1,
- "observableQuery": ObservableQuery {
- "_subscriber": [Function],
- "concast": Concast {
- "_subscriber": [Function],
- "addCount": 1,
- "cancel": [Function],
- "handlers": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- Object {
- "error": [Function],
- "next": [Function],
- },
- },
- "promise": Promise {},
- "reject": [Function],
- "resolve": [Function],
- "sources": Array [],
- "sub": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- "initialFetchPolicy": "cache-and-network",
- "isTornDown": false,
- "last": Object {
- "result": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- "variables": Object {},
- },
- "observer": Object {
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- SubscriptionObserver {
- "_subscription": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": undefined,
- "error": [Function],
- "next": [Function],
- },
- "_queue": Array [
- Object {
- "type": "next",
- "value": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- },
- ],
- "_state": "buffering",
- },
- },
- },
- "options": Object {
- "fetchPolicy": "cache-and-network",
- "notifyOnNetworkStatusChange": false,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- "queryId": "1",
- "queryInfo": [Circular],
- "queryManager": QueryManager {
- "assumeImmutableResults": false,
- "cache": [Circular],
- "clientAwareness": Object {
- "name": undefined,
- "version": undefined,
- },
- "fetchCancelFns": Map {
- "1" => [Function],
- },
- "inFlightLinkObservables": Map {
- Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- } => Map {
- "{}" => Concast {
- "_subscriber": [Function],
- "addCount": 1,
- "cancel": [Function],
- "handlers": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- SubscriptionObserver {
- "_subscription": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- },
- "promise": Promise {},
- "reject": [Function],
- "resolve": [Function],
- "sources": Array [],
- "sub": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- },
- },
- "link": MockLink {
- "addTypename": false,
- "mockedResponsesByKey": Object {
- "{\\"query\\":\\"mutation MergeCartsAfterSignIn($sourceCartId: String!, $destinationCartId: String!) {\\\\n mergeCarts(\\\\n source_cart_id: $sourceCartId\\\\n destination_cart_id: $destinationCartId\\\\n ) {\\\\n id\\\\n items {\\\\n uid\\\\n }\\\\n ...CheckoutPageFragment\\\\n }\\\\n}\\\\n\\\\nfragment CheckoutPageFragment on Cart {\\\\n id\\\\n items {\\\\n uid\\\\n product {\\\\n uid\\\\n stock_status\\\\n }\\\\n }\\\\n total_quantity\\\\n available_payment_methods {\\\\n code\\\\n }\\\\n}\\\\n\\"}": Array [
- Object {
- "request": Object {
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "MergeCartsAfterSignIn",
- },
- "operation": "mutation",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "source_cart_id",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "sourceCartId",
- },
- },
- },
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "destination_cart_id",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "destinationCartId",
- },
- },
- },
- ],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "mergeCarts",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "id",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "items",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- Object {
- "directives": Array [],
- "kind": "FragmentSpread",
- "name": Object {
- "kind": "Name",
- "value": "CheckoutPageFragment",
- },
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "sourceCartId",
- },
- },
- },
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "destinationCartId",
- },
- },
- },
- ],
- },
- Object {
- "directives": Array [],
- "kind": "FragmentDefinition",
- "name": Object {
- "kind": "Name",
- "value": "CheckoutPageFragment",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "id",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "items",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "product",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "stock_status",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "total_quantity",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "available_payment_methods",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "code",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "typeCondition": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "Cart",
- },
- },
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 932,
- "start": 0,
- },
- },
- "variables": Object {
- "destinationCartId": "new-cart-id",
- "sourceCartId": "old-cart-id",
- },
- },
- "result": Object {
- "data": null,
- },
- },
- ],
- "{\\"query\\":\\"mutation SignIn($email: String!, $password: String!) {\\\\n generateCustomerToken(email: $email, password: $password) {\\\\n token\\\\n customer_token_lifetime\\\\n }\\\\n}\\\\n\\"}": Array [
- Object {
- "request": Object {
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "SignIn",
- },
- "operation": "mutation",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- },
- },
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- },
- },
- ],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "generateCustomerToken",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "token",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "customer_token_lifetime",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- },
- },
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- },
- },
- ],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 198,
- "start": 0,
- },
- },
- "variables": Object {
- "email": "fry@planetexpress.com",
- "password": "slurm is the best",
- },
- },
- "result": Object {
- "data": Object {
- "generateCustomerToken": Object {
- "customer_token_lifetime": 3600,
- "token": "auth-token-123",
- },
- },
- },
- },
- ],
- },
- "operation": Object {
- "extensions": Object {},
- "operationName": "GetReCaptchaV3Config",
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- },
- "localState": [Circular],
- "mutationIdCounter": 1,
- "mutationStore": Object {},
- "onBroadcast": [Function],
- "queries": Map {
- "1" => [Circular],
- },
- "queryDeduplication": true,
- "queryIdCounter": 2,
- "requestIdCounter": 2,
- "ssrMode": false,
- "transformCache": WeakMap {},
- },
- "queryName": "GetReCaptchaV3Config",
- "subscriptions": Set {},
- },
- "oqListener": [Function],
- "queryId": "1",
- "stopped": false,
- "subscriptions": Set {},
- "variables": Object {},
- },
- },
- },
- },
- "client": [Circular],
- },
- "mutate": [Function],
- "query": [Function],
- "queryDeduplication": true,
- "queryManager": QueryManager {
- "assumeImmutableResults": false,
- "cache": InMemoryCache {
- "addTypename": false,
- "config": Object {
- "addTypename": false,
- "canonizeResults": false,
- "dataIdFromObject": [Function],
- "resultCaching": true,
- },
- "data": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": [Circular],
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "toReference": [Function],
- },
- "evict": [Function],
- "getFragmentDoc": [Function],
- "makeVar": [Function],
- "maybeBroadcastWatch": [Function],
- "modify": [Function],
- "optimisticData": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": [Circular],
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "reset": [Function],
- "storeReader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- "storeWriter": StoreWriter {
- "cache": [Circular],
- "reader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- },
- "txCount": 0,
- "typenameDocumentCache": Map {},
- "watches": Set {
- Object {
- "callback": [Function],
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- "watcher": QueryInfo {
- "cache": [Circular],
- "cancel": [Function],
- "dirty": false,
- "document": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "graphQLErrors": Array [],
- "lastDiff": Object {
- "diff": Object {
- "complete": false,
- "missing": Array [
- MissingFieldError {
- "message": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- "path": Object {
- "recaptchaV3Config": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- },
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- ],
- "result": Object {},
- },
- "options": Object {
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- },
- },
- "lastRequestId": 1,
- "lastWatch": [Circular],
- "listeners": Set {
- [Function],
- },
- "networkError": null,
- "networkStatus": 1,
- "observableQuery": ObservableQuery {
- "_subscriber": [Function],
- "concast": Concast {
- "_subscriber": [Function],
- "addCount": 1,
- "cancel": [Function],
- "handlers": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- Object {
- "error": [Function],
- "next": [Function],
- },
- },
- "promise": Promise {},
- "reject": [Function],
- "resolve": [Function],
- "sources": Array [],
- "sub": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- "initialFetchPolicy": "cache-and-network",
- "isTornDown": false,
- "last": Object {
- "result": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- "variables": Object {},
- },
- "observer": Object {
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- SubscriptionObserver {
- "_subscription": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": undefined,
- "error": [Function],
- "next": [Function],
- },
- "_queue": Array [
- Object {
- "type": "next",
- "value": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- },
- ],
- "_state": "buffering",
- },
- },
- },
- "options": Object {
- "fetchPolicy": "cache-and-network",
- "notifyOnNetworkStatusChange": false,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- "queryId": "1",
- "queryInfo": [Circular],
- "queryManager": [Circular],
- "queryName": "GetReCaptchaV3Config",
- "subscriptions": Set {},
- },
- "oqListener": [Function],
- "queryId": "1",
- "stopped": false,
- "subscriptions": Set {},
- "variables": Object {},
- },
- },
- },
- },
- "clientAwareness": Object {
- "name": undefined,
- "version": undefined,
- },
- "fetchCancelFns": Map {
- "1" => [Function],
- },
- "inFlightLinkObservables": Map {
- Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- } => Map {
- "{}" => Concast {
- "_subscriber": [Function],
- "addCount": 1,
- "cancel": [Function],
- "handlers": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- SubscriptionObserver {
- "_subscription": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- },
- "promise": Promise {},
- "reject": [Function],
- "resolve": [Function],
- "sources": Array [],
- "sub": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- },
- },
- "link": MockLink {
- "addTypename": false,
- "mockedResponsesByKey": Object {
- "{\\"query\\":\\"mutation MergeCartsAfterSignIn($sourceCartId: String!, $destinationCartId: String!) {\\\\n mergeCarts(\\\\n source_cart_id: $sourceCartId\\\\n destination_cart_id: $destinationCartId\\\\n ) {\\\\n id\\\\n items {\\\\n uid\\\\n }\\\\n ...CheckoutPageFragment\\\\n }\\\\n}\\\\n\\\\nfragment CheckoutPageFragment on Cart {\\\\n id\\\\n items {\\\\n uid\\\\n product {\\\\n uid\\\\n stock_status\\\\n }\\\\n }\\\\n total_quantity\\\\n available_payment_methods {\\\\n code\\\\n }\\\\n}\\\\n\\"}": Array [
- Object {
- "request": Object {
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "MergeCartsAfterSignIn",
- },
- "operation": "mutation",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "source_cart_id",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "sourceCartId",
- },
- },
- },
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "destination_cart_id",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "destinationCartId",
- },
- },
- },
- ],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "mergeCarts",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "id",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "items",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- Object {
- "directives": Array [],
- "kind": "FragmentSpread",
- "name": Object {
- "kind": "Name",
- "value": "CheckoutPageFragment",
- },
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "sourceCartId",
- },
- },
- },
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "destinationCartId",
- },
- },
- },
- ],
- },
- Object {
- "directives": Array [],
- "kind": "FragmentDefinition",
- "name": Object {
- "kind": "Name",
- "value": "CheckoutPageFragment",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "id",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "items",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "product",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "uid",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "stock_status",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "total_quantity",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "available_payment_methods",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "code",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "typeCondition": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "Cart",
- },
- },
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 932,
- "start": 0,
- },
- },
- "variables": Object {
- "destinationCartId": "new-cart-id",
- "sourceCartId": "old-cart-id",
- },
- },
- "result": Object {
- "data": null,
- },
- },
- ],
- "{\\"query\\":\\"mutation SignIn($email: String!, $password: String!) {\\\\n generateCustomerToken(email: $email, password: $password) {\\\\n token\\\\n customer_token_lifetime\\\\n }\\\\n}\\\\n\\"}": Array [
- Object {
- "request": Object {
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "SignIn",
- },
- "operation": "mutation",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- },
- },
- Object {
- "kind": "Argument",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- "value": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- },
- },
- ],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "generateCustomerToken",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "token",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "customer_token_lifetime",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "email",
- },
- },
- },
- Object {
- "defaultValue": undefined,
- "directives": Array [],
- "kind": "VariableDefinition",
- "type": Object {
- "kind": "NonNullType",
- "type": Object {
- "kind": "NamedType",
- "name": Object {
- "kind": "Name",
- "value": "String",
- },
- },
- },
- "variable": Object {
- "kind": "Variable",
- "name": Object {
- "kind": "Name",
- "value": "password",
- },
- },
- },
- ],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 198,
- "start": 0,
- },
- },
- "variables": Object {
- "email": "fry@planetexpress.com",
- "password": "slurm is the best",
- },
- },
- "result": Object {
- "data": Object {
- "generateCustomerToken": Object {
- "customer_token_lifetime": 3600,
- "token": "auth-token-123",
- },
- },
- },
- },
- ],
- },
- "operation": Object {
- "extensions": Object {},
- "operationName": "GetReCaptchaV3Config",
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- },
- "localState": LocalState {
- "cache": InMemoryCache {
- "addTypename": false,
- "config": Object {
- "addTypename": false,
- "canonizeResults": false,
- "dataIdFromObject": [Function],
- "resultCaching": true,
- },
- "data": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": [Circular],
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "toReference": [Function],
- },
- "evict": [Function],
- "getFragmentDoc": [Function],
- "makeVar": [Function],
- "maybeBroadcastWatch": [Function],
- "modify": [Function],
- "optimisticData": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": [Circular],
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "reset": [Function],
- "storeReader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- "storeWriter": StoreWriter {
- "cache": [Circular],
- "reader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- },
- "txCount": 0,
- "typenameDocumentCache": Map {},
- "watches": Set {
- Object {
- "callback": [Function],
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- "watcher": QueryInfo {
- "cache": [Circular],
- "cancel": [Function],
- "dirty": false,
- "document": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "graphQLErrors": Array [],
- "lastDiff": Object {
- "diff": Object {
- "complete": false,
- "missing": Array [
- MissingFieldError {
- "message": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- "path": Object {
- "recaptchaV3Config": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- },
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- ],
- "result": Object {},
- },
- "options": Object {
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- },
- },
- "lastRequestId": 1,
- "lastWatch": [Circular],
- "listeners": Set {
- [Function],
- },
- "networkError": null,
- "networkStatus": 1,
- "observableQuery": ObservableQuery {
- "_subscriber": [Function],
- "concast": Concast {
- "_subscriber": [Function],
- "addCount": 1,
- "cancel": [Function],
- "handlers": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- Object {
- "error": [Function],
- "next": [Function],
- },
- },
- "promise": Promise {},
- "reject": [Function],
- "resolve": [Function],
- "sources": Array [],
- "sub": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- "initialFetchPolicy": "cache-and-network",
- "isTornDown": false,
- "last": Object {
- "result": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- "variables": Object {},
- },
- "observer": Object {
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- SubscriptionObserver {
- "_subscription": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": undefined,
- "error": [Function],
- "next": [Function],
- },
- "_queue": Array [
- Object {
- "type": "next",
- "value": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- },
- ],
- "_state": "buffering",
- },
- },
- },
- "options": Object {
- "fetchPolicy": "cache-and-network",
- "notifyOnNetworkStatusChange": false,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- "queryId": "1",
- "queryInfo": [Circular],
- "queryManager": [Circular],
- "queryName": "GetReCaptchaV3Config",
- "subscriptions": Set {},
- },
- "oqListener": [Function],
- "queryId": "1",
- "stopped": false,
- "subscriptions": Set {},
- "variables": Object {},
- },
- },
- },
- },
- "client": [Circular],
- },
- "mutationIdCounter": 1,
- "mutationStore": Object {},
- "onBroadcast": [Function],
- "queries": Map {
- "1" => QueryInfo {
- "cache": InMemoryCache {
- "addTypename": false,
- "config": Object {
- "addTypename": false,
- "canonizeResults": false,
- "dataIdFromObject": [Function],
- "resultCaching": true,
- },
- "data": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": [Circular],
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "toReference": [Function],
- },
- "evict": [Function],
- "getFragmentDoc": [Function],
- "makeVar": [Function],
- "maybeBroadcastWatch": [Function],
- "modify": [Function],
- "optimisticData": Stump {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- "parent": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- },
- "id": "EntityStore.Stump",
- "parent": Root {
- "canRead": [Function],
- "data": Object {},
- "getFieldValue": [Function],
- "group": CacheGroup {
- "caching": true,
- "d": [Function],
- "keyMaker": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "parent": null,
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "rootIds": Object {},
- "storageTrie": Trie {
- "makeData": [Function],
- "weakness": true,
- },
- "stump": [Circular],
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "refs": Object {},
- "replay": [Function],
- "rootIds": Object {},
- "toReference": [Function],
- },
- "policies": Policies {
- "cache": [Circular],
- "config": Object {
- "cache": [Circular],
- "dataIdFromObject": [Function],
- "possibleTypes": undefined,
- "typePolicies": undefined,
- },
- "fuzzySubtypes": Map {},
- "rootIdsByTypename": Object {
- "Mutation": "ROOT_MUTATION",
- "Query": "ROOT_QUERY",
- "Subscription": "ROOT_SUBSCRIPTION",
- },
- "rootTypenamesById": Object {
- "ROOT_MUTATION": "Mutation",
- "ROOT_QUERY": "Query",
- "ROOT_SUBSCRIPTION": "Subscription",
- },
- "supertypeMap": Map {},
- "toBeAdded": Object {},
- "typePolicies": Object {
- "Query": Object {
- "fields": Object {},
- },
- },
- "usingPossibleTypes": false,
- },
- "reset": [Function],
- "storeReader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- "storeWriter": StoreWriter {
- "cache": [Circular],
- "reader": StoreReader {
- "canon": ObjectCanon {
- "empty": Object {},
- "keysByJSON": Map {
- "[]" => Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "known": WeakSet {},
- "passes": WeakMap {},
- "pool": Trie {
- "data": Object {
- "keys": Object {
- "json": "[]",
- "sorted": Array [],
- },
- },
- "makeData": [Function],
- "weak": WeakMap {},
- "weakness": true,
- },
- },
- "config": Object {
- "addTypename": false,
- "cache": [Circular],
- "canonizeResults": false,
- },
- "executeSelectionSet": [Function],
- "executeSubSelectedArray": [Function],
- "knownResults": WeakMap {},
- },
- },
- "txCount": 0,
- "typenameDocumentCache": Map {},
- "watches": Set {
- Object {
- "callback": [Function],
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- "watcher": [Circular],
- },
- },
- },
- "cancel": [Function],
- "dirty": false,
- "document": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "graphQLErrors": Array [],
- "lastDiff": Object {
- "diff": Object {
- "complete": false,
- "missing": Array [
- MissingFieldError {
- "message": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- "path": Object {
- "recaptchaV3Config": "Can't find field 'recaptchaV3Config' on ROOT_QUERY object",
- },
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- ],
- "result": Object {},
- },
- "options": Object {
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- },
- },
- "lastRequestId": 1,
- "lastWatch": Object {
- "callback": [Function],
- "canonizeResults": undefined,
- "optimistic": true,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "returnPartialData": true,
- "variables": Object {},
- "watcher": [Circular],
- },
- "listeners": Set {
- [Function],
- },
- "networkError": null,
- "networkStatus": 1,
- "observableQuery": ObservableQuery {
- "_subscriber": [Function],
- "concast": Concast {
- "_subscriber": [Function],
- "addCount": 1,
- "cancel": [Function],
- "handlers": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- Object {
- "error": [Function],
- "next": [Function],
- },
- },
- "promise": Promise {},
- "reject": [Function],
- "resolve": [Function],
- "sources": Array [],
- "sub": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": [Function],
- "error": [Function],
- "next": [Function],
- },
- "_queue": undefined,
- "_state": "ready",
- },
- },
- "initialFetchPolicy": "cache-and-network",
- "isTornDown": false,
- "last": Object {
- "result": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- "variables": Object {},
- },
- "observer": Object {
- "error": [Function],
- "next": [Function],
- },
- "observers": Set {
- SubscriptionObserver {
- "_subscription": Subscription {
- "_cleanup": [Function],
- "_observer": Object {
- "complete": undefined,
- "error": [Function],
- "next": [Function],
- },
- "_queue": Array [
- Object {
- "type": "next",
- "value": Object {
- "loading": true,
- "networkStatus": 1,
- "partial": true,
- },
- },
- ],
- "_state": "buffering",
- },
- },
- },
- "options": Object {
- "fetchPolicy": "cache-and-network",
- "notifyOnNetworkStatusChange": false,
- "query": Object {
- "definitions": Array [
- Object {
- "directives": Array [],
- "kind": "OperationDefinition",
- "name": Object {
- "kind": "Name",
- "value": "GetReCaptchaV3Config",
- },
- "operation": "query",
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "recaptchaV3Config",
- },
- "selectionSet": Object {
- "kind": "SelectionSet",
- "selections": Array [
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "website_key",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "badge_position",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "language_code",
- },
- "selectionSet": undefined,
- },
- Object {
- "alias": undefined,
- "arguments": Array [],
- "directives": Array [],
- "kind": "Field",
- "name": Object {
- "kind": "Name",
- "value": "forms",
- },
- "selectionSet": undefined,
- },
- ],
- },
- },
- ],
- },
- "variableDefinitions": Array [],
- },
- ],
- "kind": "Document",
- "loc": Object {
- "end": 173,
- "start": 0,
- },
- },
- "variables": Object {},
- },
- "queryId": "1",
- "queryInfo": [Circular],
- "queryManager": [Circular],
- "queryName": "GetReCaptchaV3Config",
- "subscriptions": Set {},
- },
- "oqListener": [Function],
- "queryId": "1",
- "stopped": false,
- "subscriptions": Set {},
- "variables": Object {},
- },
- },
- "queryDeduplication": true,
- "queryIdCounter": 2,
- "requestIdCounter": 2,
- "ssrMode": false,
- "transformCache": WeakMap {},
- },
- "reFetchObservableQueries": [Function],
- "resetStore": [Function],
- "resetStoreCallbacks": Array [],
- "typeDefs": undefined,
- "version": "3.5.10",
- "watchQuery": [Function],
- },
- "loading": false,
- "reset": [Function],
- },
- ],
- "signinHandleEnterKeyPress": [Function],
- "userContext": Array [
- Object {
- "getDetailsError": "getDetails error from redux",
- "isGettingDetails": false,
- },
- Object {
- "getUserDetails": [MockFunction],
- "setToken": [MockFunction],
- },
- ],
- }
- `);
+ expect(talonProps).toMatchSnapshot();
+});
+test('should set isBusy to true', () => {
+ const { talonProps, update } = getTalonProps({
+ ...defaultProps
+ });
+ talonProps.handleSubmit(signInVariables);
+
+ const { isBusy } = update();
+
+ expect(isBusy).toBeTruthy();
});
test('handleSubmit triggers waterfall of operations and actions', async () => {
- useAwaitQuery.mockReturnValueOnce(() => ({
+ const token = 'customertoken';
+ const customer_token_lifetime = 1;
+ const signIn = jest.fn().mockReturnValue({
data: {
- customer: {
- email: 'john@fake.email'
+ generateCustomerToken: {
+ token
}
}
- }));
-
- const [, { getCartDetails }] = useCartContext();
- const [, { getUserDetails, setToken }] = useUserContext();
- const [, { dispatch }] = useEventingContext();
-
- const { result } = renderHookWithProviders();
-
- await act(() => result.current.handleSubmit(signInVariables));
-
- expect(result.current.isBusy).toBe(true);
- expect(setToken).toHaveBeenCalledWith(authToken, customerTokenLifetime);
- expect(getCartDetails).toHaveBeenCalled();
- expect(getUserDetails).toHaveBeenCalled();
-
- expect(dispatch).toHaveBeenCalledTimes(1);
- expect(dispatch.mock.calls[0][0]).toMatchInlineSnapshot(`
- Object {
- "payload": Object {
- "email": "john@fake.email",
- },
- "type": "USER_SIGN_IN",
+ });
+ signInMutationFn.mockReturnValueOnce([signIn, { error: null }]);
+ const setToken = jest.fn();
+ useUserContext.mockReturnValueOnce([
+ { isGettingDetails: false },
+ { getUserDetails: jest.fn(), setToken }
+ ]);
+
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
+
+ await talonProps.handleSubmit(signInVariables);
+ expect(signIn).toHaveBeenCalledWith({
+ variables: {
+ email: signInVariables.email,
+ password: signInVariables.password
}
- `);
+ });
+ expect(setToken).toHaveBeenCalledWith(token, customer_token_lifetime);
});
test('handleSubmit exception is logged and resets state', async () => {
- const errorMessage = 'Oh no! Something went wrong :(';
- const [, { getUserDetails, setToken }] = useUserContext();
- setToken.mockRejectedValue(errorMessage);
- jest.spyOn(console, 'error');
-
- const { result } = renderHookWithProviders();
+ const fetchUserDetails = jest.fn();
+ customerQueryFn.mockReturnValueOnce(fetchUserDetails);
+ const getUserDetails = jest.fn();
+ useUserContext.mockReturnValueOnce([
+ { isGettingDetails: false },
+ { getUserDetails: jest.fn(), setToken: jest.fn() }
+ ]);
- await act(() => result.current.handleSubmit(signInVariables));
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
- expect(result.current.isBusy).toBe(false);
+ expect(talonProps.isBusy).toBeFalsy();
expect(getUserDetails).not.toHaveBeenCalled();
- expect(console.error).toHaveBeenCalledWith(errorMessage);
});
-test('handleForgotPassword triggers callbacks', () => {
+test('handleForgotPassword triggers callbacks', async () => {
+ const setDefaultUsername = jest.fn();
+ const showForgotPassword = jest.fn();
+ const { talonProps } = getTalonProps({
+ ...defaultProps,
+ setDefaultUsername,
+ showForgotPassword
+ });
const mockUsername = 'fry@planetexpress.com';
const mockApi = {
getValue: jest.fn().mockReturnValue(mockUsername)
};
-
- const { result } = renderHookWithProviders();
- act(() => result.current.setFormApi(mockApi));
- act(() => result.current.handleForgotPassword());
-
- expect(initialProps.setDefaultUsername).toHaveBeenCalledWith(mockUsername);
- expect(initialProps.showForgotPassword).toHaveBeenCalled();
+ await talonProps.setFormApi(mockApi);
+ await talonProps.handleForgotPassword();
+ expect(setDefaultUsername).toHaveBeenCalledWith(mockUsername);
+ expect(showForgotPassword).toHaveBeenCalled();
});
-test('handleCreateAccount triggers callbacks', () => {
+test('handleCreateAccount triggers callbacks', async () => {
+ const setDefaultUsername = jest.fn();
+ const showCreateAccount = jest.fn();
+ const { talonProps } = getTalonProps({
+ ...defaultProps,
+ setDefaultUsername,
+ showCreateAccount
+ });
const mockUsername = 'fry@planetexpress.com';
const mockApi = {
getValue: jest.fn().mockReturnValue(mockUsername)
};
-
- const { result } = renderHookWithProviders();
- act(() => result.current.setFormApi(mockApi));
- act(() => result.current.handleCreateAccount());
-
- expect(initialProps.setDefaultUsername).toHaveBeenCalledWith(mockUsername);
- expect(initialProps.showCreateAccount).toHaveBeenCalled();
+ await talonProps.setFormApi(mockApi);
+ await talonProps.handleCreateAccount();
+ expect(setDefaultUsername).toHaveBeenCalledWith(mockUsername);
+ expect(showCreateAccount).toHaveBeenCalled();
});
test('mutation error is returned by talon', async () => {
- const signInErrorMock = {
- request: signInMock.request,
- error: new Error('Uh oh! There was an error signing in :(')
- };
-
- const { result } = renderHookWithProviders({ mocks: [signInErrorMock] });
- await act(() => result.current.handleSubmit(signInVariables));
-
- expect(result.current.errors.get('signInMutation')).toMatchInlineSnapshot(
- `[Error: Uh oh! There was an error signing in :(]`
- );
+ const getUserDetailsQuery = jest.fn();
+ getUserDetailsQuery.mockReturnValueOnce([
+ jest.fn(),
+ { error: 'getDetails error from redux' }
+ ]);
+ signInMutationFn.mockReturnValueOnce([
+ jest.fn(),
+ { error: 'Sign In Mutation Error' }
+ ]);
+
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
+
+ await talonProps.handleSubmit(signInVariables);
+ expect(talonProps.errors).toMatchSnapshot();
});
it('should call handleForgotPassword when Enter key is pressed', () => {
- const { result } = renderHookWithProviders();
- const { forgotPasswordHandleEnterKeyPress } = result.current;
- const enterKeyEvent = { key: 'Enter' };
- renderHook(() => forgotPasswordHandleEnterKeyPress(enterKeyEvent));
-});
-
-it('should call handleEnterKeyPress when Enter key is pressed', () => {
- const { result } = renderHookWithProviders();
- const { handleEnterKeyPress } = result.current;
+ const { talonProps } = getTalonProps({
+ ...defaultProps
+ });
const enterKeyEvent = { key: 'Enter' };
- renderHook(() => handleEnterKeyPress(enterKeyEvent));
+ talonProps.forgotPasswordHandleEnterKeyPress(enterKeyEvent);
});
diff --git a/packages/peregrine/lib/talons/SignIn/signIn.gql.js b/packages/peregrine/lib/talons/SignIn/signIn.gql.js
index b960c3452e..0c91e813b0 100644
--- a/packages/peregrine/lib/talons/SignIn/signIn.gql.js
+++ b/packages/peregrine/lib/talons/SignIn/signIn.gql.js
@@ -1,5 +1,6 @@
import { gql } from '@apollo/client';
import { CheckoutPageFragment } from '../CheckoutPage/checkoutPageFragments.gql';
+import { GET_STORE_CONFIG_DATA } from '../CreateAccount/createAccount.gql';
export const GET_CUSTOMER = gql`
query GetCustomerAfterSignIn {
@@ -17,7 +18,6 @@ export const SIGN_IN = gql`
mutation SignIn($email: String!, $password: String!) {
generateCustomerToken(email: $email, password: $password) {
token
- customer_token_lifetime
}
}
`;
@@ -52,5 +52,6 @@ export default {
createCartMutation: CREATE_CART,
getCustomerQuery: GET_CUSTOMER,
mergeCartsMutation: MERGE_CARTS,
- signInMutation: SIGN_IN
+ signInMutation: SIGN_IN,
+ getStoreConfigQuery: GET_STORE_CONFIG_DATA
};
diff --git a/packages/peregrine/lib/talons/SignIn/useSignIn.js b/packages/peregrine/lib/talons/SignIn/useSignIn.js
index afedbcc05a..34fb99f043 100644
--- a/packages/peregrine/lib/talons/SignIn/useSignIn.js
+++ b/packages/peregrine/lib/talons/SignIn/useSignIn.js
@@ -1,5 +1,5 @@
import { useCallback, useRef, useState, useMemo } from 'react';
-import { useApolloClient, useMutation } from '@apollo/client';
+import { useApolloClient, useMutation, useQuery } from '@apollo/client';
import { useGoogleReCaptcha } from '../../hooks/useGoogleReCaptcha/useGoogleReCaptcha';
import mergeOperations from '../../util/shallowMerge';
@@ -25,7 +25,8 @@ export const useSignIn = props => {
createCartMutation,
getCustomerQuery,
mergeCartsMutation,
- signInMutation
+ signInMutation,
+ getStoreConfigQuery
} = operations;
const apolloClient = useApolloClient();
@@ -61,6 +62,19 @@ export const useSignIn = props => {
recaptchaWidgetProps
} = googleReCaptcha;
+ const { data: storeConfigData } = useQuery(getStoreConfigQuery, {
+ fetchPolicy: 'cache-and-network',
+ nextFetchPolicy: 'cache-first'
+ });
+
+ const { customerAccessTokenLifetime } = useMemo(() => {
+ const storeConfig = storeConfigData?.storeConfig || {};
+
+ return {
+ customerAccessTokenLifetime:
+ storeConfig.customer_access_token_lifetime
+ };
+ }, [storeConfigData]);
const [fetchCartId] = useMutation(createCartMutation);
const [mergeCarts] = useMutation(mergeCartsMutation);
const fetchUserDetails = useAwaitQuery(getCustomerQuery);
@@ -91,12 +105,8 @@ export const useSignIn = props => {
});
const token = signInResponse.data.generateCustomerToken.token;
- const customerTokenLifetime =
- signInResponse.data.generateCustomerToken
- .customer_token_lifetime;
-
- await (customerTokenLifetime
- ? setToken(token, customerTokenLifetime)
+ await (customerAccessTokenLifetime
+ ? setToken(token, customerAccessTokenLifetime)
: setToken(token));
// Clear all cart/customer data from cache and redux.
@@ -143,6 +153,7 @@ export const useSignIn = props => {
}
},
[
+ customerAccessTokenLifetime,
cartId,
generateReCaptchaData,
signIn,
diff --git a/packages/peregrine/package.json b/packages/peregrine/package.json
index 02cdd295ec..432a36360b 100644
--- a/packages/peregrine/package.json
+++ b/packages/peregrine/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/peregrine",
- "version": "14.3.1",
+ "version": "14.4.1",
"publishConfig": {
"access": "public"
},
diff --git a/packages/venia-concept/package.json b/packages/venia-concept/package.json
index 0f0e5585c9..ea35e6279e 100644
--- a/packages/venia-concept/package.json
+++ b/packages/venia-concept/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/venia-concept",
- "version": "14.0.1",
+ "version": "14.1.0",
"publishConfig": {
"access": "public"
},
@@ -52,11 +52,11 @@
"@babel/runtime": "~7.15.3",
"@magento/babel-preset-peregrine": "~1.3.3",
"@magento/eslint-config": "~1.5.0",
- "@magento/pagebuilder": "~9.3.1",
- "@magento/peregrine": "~14.3.1",
+ "@magento/pagebuilder": "~9.3.2",
+ "@magento/peregrine": "~14.4.1",
"@magento/pwa-theme-venia": "~2.4.0",
"@magento/upward-security-headers": "~1.0.14",
- "@magento/venia-ui": "~11.4.0",
+ "@magento/venia-ui": "~11.5.0",
"@pmmmwh/react-refresh-webpack-plugin": "0.4.1",
"@storybook/react": "~6.3.7",
"@types/node": "16",
diff --git a/packages/venia-ui/lib/components/CheckoutPage/OrderConfirmationPage/createAccount.js b/packages/venia-ui/lib/components/CheckoutPage/OrderConfirmationPage/createAccount.js
index ef56003fa5..4256fccd6d 100644
--- a/packages/venia-ui/lib/components/CheckoutPage/OrderConfirmationPage/createAccount.js
+++ b/packages/venia-ui/lib/components/CheckoutPage/OrderConfirmationPage/createAccount.js
@@ -65,7 +65,8 @@ const CreateAccount = props => {
handleSubmit,
isDisabled,
initialValues,
- recaptchaWidgetProps
+ recaptchaWidgetProps,
+ minimumPasswordLength
} = talonProps;
return (
@@ -155,7 +156,7 @@ const CreateAccount = props => {
data-cy="OrderConfirmationPage-CreateAccount-password"
validate={combine([
isRequired,
- [hasLengthAtLeast, 8],
+ [hasLengthAtLeast, minimumPasswordLength],
validatePassword
])}
validateOnBlur
diff --git a/packages/venia-ui/lib/components/CreateAccount/__tests__/createAccount.spec.js b/packages/venia-ui/lib/components/CreateAccount/__tests__/createAccount.spec.js
index ad84b877d1..c174a60ae3 100644
--- a/packages/venia-ui/lib/components/CreateAccount/__tests__/createAccount.spec.js
+++ b/packages/venia-ui/lib/components/CreateAccount/__tests__/createAccount.spec.js
@@ -14,7 +14,11 @@ jest.mock('@apollo/client', () => ({
}
]),
useQuery: jest.fn().mockImplementation(() => ({
- data: {},
+ data: {
+ storeConfig: {
+ minimum_password_length: 8 // or whatever value is expected
+ }
+ },
loading: false,
error: null
}))
diff --git a/packages/venia-ui/lib/components/CreateAccount/createAccount.js b/packages/venia-ui/lib/components/CreateAccount/createAccount.js
index 31fa9a17a1..84ababb1fe 100644
--- a/packages/venia-ui/lib/components/CreateAccount/createAccount.js
+++ b/packages/venia-ui/lib/components/CreateAccount/createAccount.js
@@ -35,8 +35,10 @@ const CreateAccount = props => {
handleCancelKeyPress,
isDisabled,
initialValues,
- recaptchaWidgetProps
+ recaptchaWidgetProps,
+ minimumPasswordLength
} = talonProps;
+ console.log('minimumPasswordLength==', minimumPasswordLength);
const { formatMessage } = useIntl();
const classes = useStyle(defaultClasses, props.classes);
@@ -164,7 +166,7 @@ const CreateAccount = props => {
})}
validate={combine([
isRequired,
- [hasLengthAtLeast, 8],
+ [hasLengthAtLeast, minimumPasswordLength],
validatePassword
])}
validateOnBlur
diff --git a/packages/venia-ui/package.json b/packages/venia-ui/package.json
index c2cc1e518f..cc0a976e3b 100644
--- a/packages/venia-ui/package.json
+++ b/packages/venia-ui/package.json
@@ -1,6 +1,6 @@
{
"name": "@magento/venia-ui",
- "version": "11.4.0",
+ "version": "11.5.0",
"publishConfig": {
"access": "public"
},
@@ -80,7 +80,7 @@
"peerDependencies": {
"@apollo/client": "~3.5.0",
"@magento/babel-preset-peregrine": "~1.3.3",
- "@magento/peregrine": "~14.3.1",
+ "@magento/peregrine": "~14.4.1",
"@magento/pwa-buildpack": "~11.5.3",
"apollo-cache-persist": "~0.1.1",
"braintree-web-drop-in": "~1.33.3",
diff --git a/pwa-devdocs/package.json b/pwa-devdocs/package.json
index 4677290bce..49a7c291dc 100644
--- a/pwa-devdocs/package.json
+++ b/pwa-devdocs/package.json
@@ -1,7 +1,7 @@
{
"name": "pwa-devdocs",
"private": true,
- "version": "14.0.1",
+ "version": "14.1.0",
"description": "A documentation site for Magento PWA",
"main": "gulpfile.js",
"dependencies": {