diff --git a/packages/commerce-sdk-react/CHANGELOG.md b/packages/commerce-sdk-react/CHANGELOG.md index 09a39ae3f7..94d04c4727 100644 --- a/packages/commerce-sdk-react/CHANGELOG.md +++ b/packages/commerce-sdk-react/CHANGELOG.md @@ -1,6 +1,8 @@ ## v3.4.0-dev.0 (May 23, 2025) - Now compatible with either React 17 and 18 [#2506](https://github.com/SalesforceCommerceCloud/pwa-kit/pull/2506) +- Refactor commerce-sdk-react to allow injecting ApiClients [#2519](https://github.com/SalesforceCommerceCloud/pwa-kit/pull/2519) + ## v3.3.0 (May 22, 2025) - Fix inconsistency between dwsid and access token for guest login when hybrid authentication is enabled [#2397](https://github.com/SalesforceCommerceCloud/pwa-kit/pull/2397) diff --git a/packages/commerce-sdk-react/src/hooks/types.ts b/packages/commerce-sdk-react/src/hooks/types.ts index 5b2eb07793..4f39677424 100644 --- a/packages/commerce-sdk-react/src/hooks/types.ts +++ b/packages/commerce-sdk-react/src/hooks/types.ts @@ -20,6 +20,7 @@ import { ShopperStores } from 'commerce-sdk-isomorphic' import {helpers} from 'commerce-sdk-isomorphic' +import {CommerceApiProviderProps} from '../provider' // --- GENERAL UTILITIES --- // @@ -226,3 +227,17 @@ export type TMutationVariables = { parameters?: {[key: string]: string | number | boolean | string[] | number[]} headers?: {[key: string]: string} } | void + +export type SDKClientTransformer = ( + params: T, + methodName: string, + options: any +) => any | Promise + +export type ErrorCallback = (methodName: string, error: any, params: TParams) => void + +export interface SDKClientTransformConfig> { + props: Omit + transformer?: SDKClientTransformer + onError?: ErrorCallback +} diff --git a/packages/commerce-sdk-react/src/hooks/useConfig.ts b/packages/commerce-sdk-react/src/hooks/useConfig.ts index 622f39be86..2fa32fe699 100644 --- a/packages/commerce-sdk-react/src/hooks/useConfig.ts +++ b/packages/commerce-sdk-react/src/hooks/useConfig.ts @@ -11,7 +11,7 @@ import {ConfigContext, CommerceApiProviderProps} from '../provider' /** * @Internal */ -const useConfig = (): Omit => { +const useConfig = (): Omit => { return React.useContext(ConfigContext) } diff --git a/packages/commerce-sdk-react/src/provider.tsx b/packages/commerce-sdk-react/src/provider.tsx index db578ddfc0..36b0864ba2 100644 --- a/packages/commerce-sdk-react/src/provider.tsx +++ b/packages/commerce-sdk-react/src/provider.tsx @@ -5,6 +5,15 @@ * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause */ import React, {ReactElement, useEffect, useMemo} from 'react' +import Auth from './auth' +import {ApiClientConfigParams, ApiClients, SDKClientTransformer} from './hooks/types' +import {Logger} from './types' +import { + DWSID_COOKIE_NAME, + MOBIFY_PATH, + SERVER_AFFINITY_HEADER_KEY, + SLAS_PRIVATE_PROXY_PATH +} from './constant' import { ShopperBaskets, ShopperContexts, @@ -20,15 +29,8 @@ import { ShopperBasketsTypes, ShopperStores } from 'commerce-sdk-isomorphic' -import Auth from './auth' -import {ApiClientConfigParams, ApiClients} from './hooks/types' -import {Logger} from './types' -import { - DWSID_COOKIE_NAME, - MOBIFY_PATH, - SERVER_AFFINITY_HEADER_KEY, - SLAS_PRIVATE_PROXY_PATH -} from './constant' +import {transformSDKClient} from './utils' + export interface CommerceApiProviderProps extends ApiClientConfigParams { children: React.ReactNode proxy: string @@ -46,6 +48,7 @@ export interface CommerceApiProviderProps extends ApiClientConfigParams { passwordlessLoginCallbackURI?: string refreshTokenRegisteredCookieTTL?: number refreshTokenGuestCookieTTL?: number + apiClients?: ApiClients } /** @@ -56,7 +59,9 @@ export const CommerceApiContext = React.createContext({} as ApiClients) /** * @internal */ -export const ConfigContext = React.createContext({} as Omit) +export const ConfigContext = React.createContext( + {} as Omit +) /** * @internal @@ -126,7 +131,8 @@ const CommerceApiProvider = (props: CommerceApiProviderProps): ReactElement => { defaultDnt, passwordlessLoginCallbackURI, refreshTokenRegisteredCookieTTL, - refreshTokenGuestCookieTTL + refreshTokenGuestCookieTTL, + apiClients } = props // Set the logger based on provided configuration, or default to the console object if no logger is provided @@ -167,7 +173,8 @@ const CommerceApiProvider = (props: CommerceApiProviderProps): ReactElement => { defaultDnt, passwordlessLoginCallbackURI, refreshTokenRegisteredCookieTTL, - refreshTokenGuestCookieTTL + refreshTokenGuestCookieTTL, + apiClients ]) const dwsid = auth.get(DWSID_COOKIE_NAME) @@ -176,28 +183,62 @@ const CommerceApiProvider = (props: CommerceApiProviderProps): ReactElement => { serverAffinityHeader[SERVER_AFFINITY_HEADER_KEY] = dwsid } - const config = { - proxy, - headers: { - ...headers, - ...serverAffinityHeader - }, - parameters: { - clientId, - organizationId, - shortCode, - siteId, - locale, - currency - }, - throwOnBadResponse: true, - fetchOptions + const _defaultTransformer: SDKClientTransformer> = (_, _$, options) => { + return { + ...options, + headers: { + ...options.headers, + ...serverAffinityHeader + }, + throwOnBadResponse: true, + fetchOptions: { + ...options.fetchOptions, + ...fetchOptions + } + } } - const baseUrl = config.proxy.split(MOBIFY_PATH)[0] - const privateClientEndpoint = `${baseUrl}${SLAS_PRIVATE_PROXY_PATH}` + const updatedClients: ApiClients = useMemo(() => { + if (apiClients) { + const clients: Record = {} + + // transformSDKClient is simply a utility function that wraps the SDK Client instance + // in a Proxy that allows us to transform the method arguments and modify headers, parameters, and other options. + // We don't really need to pass in the children prop to the transformer function, so we'll just pass in the rest of the props. + // eslint-disable-next-line @typescript-eslint/no-unused-vars + const {children, ...restProps} = props + + Object.entries(apiClients ?? {}).forEach(([key, apiClient]) => { + clients[key] = transformSDKClient(apiClient, { + props: restProps, + transformer: _defaultTransformer + }) + }) + + return clients as ApiClients + } + + const config = { + proxy, + headers: { + ...headers, + ...serverAffinityHeader + }, + parameters: { + clientId, + organizationId, + shortCode, + siteId, + locale, + currency + }, + throwOnBadResponse: true, + fetchOptions + } + + const baseUrl = config.proxy.split(MOBIFY_PATH)[0] + const privateClientEndpoint = `${baseUrl}${SLAS_PRIVATE_PROXY_PATH}` - const apiClients = useMemo(() => { return { shopperBaskets: new ShopperBaskets(config), shopperContexts: new ShopperContexts(config), @@ -224,7 +265,8 @@ const CommerceApiProvider = (props: CommerceApiProviderProps): ReactElement => { fetchOptions, locale, currency, - headers?.['correlation-id'] + headers?.['correlation-id'], + apiClients ]) // Initialize the session @@ -251,7 +293,7 @@ const CommerceApiProvider = (props: CommerceApiProviderProps): ReactElement => { refreshTokenGuestCookieTTL }} > - + {children} diff --git a/packages/commerce-sdk-react/src/utils.test.ts b/packages/commerce-sdk-react/src/utils.test.ts index a7dbf9b806..a2db4a652f 100644 --- a/packages/commerce-sdk-react/src/utils.test.ts +++ b/packages/commerce-sdk-react/src/utils.test.ts @@ -5,6 +5,8 @@ * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause */ import * as utils from './utils' +import {DEFAULT_TEST_CONFIG} from './test-utils' +import {SDKClientTransformConfig} from './hooks/types' describe('Utils', () => { test.each([ @@ -31,4 +33,195 @@ describe('Utils', () => { c_param3: true }) }) + + describe('transformSDKClient', () => { + let mockClient: any + let mockConfig: SDKClientTransformConfig + + beforeEach(() => { + mockClient = { + getBasket: jest.fn().mockResolvedValue({basketId: 'test-basket'}), + createBasket: jest.fn().mockResolvedValue({basketId: 'new-basket'}), + nonFunctionProperty: 'some value' + } + + mockConfig = { + props: { + ...DEFAULT_TEST_CONFIG + }, + transformer: jest.fn((params, methodName, options) => options), + onError: jest.fn() + } + }) + + afterEach(() => { + jest.clearAllMocks() + }) + + test('should return a proxy that preserves non-function properties', () => { + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + + expect(proxiedClient.nonFunctionProperty).toBe('some value') + }) + + test('should wrap function methods with proxy behavior', () => { + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + + expect(typeof proxiedClient.getBasket).toBe('function') + expect(typeof proxiedClient.createBasket).toBe('function') + }) + + test('should call original method with provided options', async () => { + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + const options = {parameters: {basketId: 'test-123'}} + + await proxiedClient.getBasket(options) + + expect(mockClient.getBasket).toHaveBeenCalledWith(options) + }) + + test('should call original method with empty object if no options provided', async () => { + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + + await proxiedClient.getBasket() + + expect(mockClient.getBasket).toHaveBeenCalledWith({}) + }) + + test('should apply transformer to options before calling original method', async () => { + const transformedOptions = { + parameters: {basketId: 'transformed-123'}, + headers: {'X-Custom': 'transformed'} + } + ;(mockConfig.transformer as jest.Mock).mockResolvedValue(transformedOptions) + + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + const originalOptions = {parameters: {basketId: 'original-123'}} + + await proxiedClient.getBasket(originalOptions) + + expect(mockConfig.transformer).toHaveBeenCalledWith( + mockConfig.props, + 'getBasket', + originalOptions + ) + expect(mockClient.getBasket).toHaveBeenCalledWith(transformedOptions) + }) + + test('should handle async transformer', async () => { + const transformedOptions = {parameters: {basketId: 'async-transformed'}} + ;(mockConfig.transformer as jest.Mock).mockResolvedValue(transformedOptions) + + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + + await proxiedClient.getBasket({}) + + expect(mockClient.getBasket).toHaveBeenCalledWith(transformedOptions) + }) + + test('should handle sync transformer', async () => { + const transformedOptions = {parameters: {basketId: 'sync-transformed'}} + ;(mockConfig.transformer as jest.Mock).mockReturnValue(transformedOptions) + + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + + await proxiedClient.getBasket({}) + + expect(mockClient.getBasket).toHaveBeenCalledWith(transformedOptions) + }) + + test('should call onError callback when method throws error', async () => { + const error = new Error('API Error') + mockClient.getBasket.mockRejectedValue(error) + + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + const options = {parameters: {basketId: 'test'}} + + await expect(proxiedClient.getBasket(options)).rejects.toThrow('API Error') + + expect(mockConfig.onError).toHaveBeenCalledWith('getBasket', error, options) + }) + + test('should rethrow error after calling onError callback', async () => { + const error = new Error('API Error') + mockClient.getBasket.mockRejectedValue(error) + + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + + await expect(proxiedClient.getBasket({})).rejects.toThrow('API Error') + }) + + test('should work without optional callbacks', async () => { + const configWithoutCallbacks = { + props: { + ...DEFAULT_TEST_CONFIG + } + } + + const proxiedClient = utils.transformSDKClient(mockClient, configWithoutCallbacks) + + await expect(proxiedClient.getBasket({})).resolves.toEqual({basketId: 'test-basket'}) + }) + + test('should work without transformer', async () => { + const configWithoutTransformer = { + props: { + ...DEFAULT_TEST_CONFIG + }, + onError: jest.fn() + } + + const proxiedClient = utils.transformSDKClient(mockClient, configWithoutTransformer) + const options = {parameters: {basketId: 'test'}} + + await proxiedClient.getBasket(options) + + expect(mockClient.getBasket).toHaveBeenCalledWith(options) + }) + + test('should handle multiple method calls independently', async () => { + const proxiedClient = utils.transformSDKClient(mockClient, mockConfig) + + await proxiedClient.getBasket({parameters: {basketId: 'basket-1'}}) + await proxiedClient.createBasket({parameters: {currency: 'USD'}}) + + expect(mockClient.getBasket).toHaveBeenCalledWith({parameters: {basketId: 'basket-1'}}) + expect(mockClient.createBasket).toHaveBeenCalledWith({parameters: {currency: 'USD'}}) + }) + + test('should preserve this context in original method calls', async () => { + const contextClient = { + getData: function () { + return Promise.resolve('test-data') + } + } + + const proxiedClient = utils.transformSDKClient(contextClient, mockConfig) + + const result = await proxiedClient.getData() + + expect(result).toBe('test-data') + }) + + test('should pass props correctly to transformer', () => { + const propsWithCustom = { + ...DEFAULT_TEST_CONFIG, + customProp: 'custom-value' + } + + const configWithCustomProps = { + props: propsWithCustom, + transformer: jest.fn((params) => { + expect(params).toHaveProperty('customProp', 'custom-value') + return {} + }) + } + + const proxiedClient = utils.transformSDKClient(mockClient, configWithCustomProps) + + proxiedClient.getBasket({}) + + expect(configWithCustomProps.transformer).toHaveBeenCalled() + }) + }) }) diff --git a/packages/commerce-sdk-react/src/utils.ts b/packages/commerce-sdk-react/src/utils.ts index 70c8ba097b..309428d079 100644 --- a/packages/commerce-sdk-react/src/utils.ts +++ b/packages/commerce-sdk-react/src/utils.ts @@ -8,6 +8,7 @@ import Cookies, {CookieAttributes} from 'js-cookie' import {IFRAME_HOST_ALLOW_LIST} from './constant' import {helpers} from 'commerce-sdk-isomorphic' +import {SDKClientTransformConfig} from './hooks/types' /** Utility to determine if you are on the browser (client) or not. */ export const onClient = (): boolean => typeof window !== 'undefined' @@ -161,3 +162,40 @@ export const extractCustomParameters = ( } return Object.fromEntries(Object.entries(parameters).filter(([key]) => key.startsWith('c_'))) } + +/** + * Creates a proxy around SDK Client instance to transform method arguments and modify headers, parameters, and other options. + * You can pass in a transformer function to modify the parameters. + * @param client - The SDK Client instance to transform. + * @param config - The configuration object for the transformation. + * @returns The transformed SDK Client instance. + */ +export const transformSDKClient = Promise>>( + client: T, + config: SDKClientTransformConfig +): T => { + const {props, transformer, onError} = config + + return new Proxy(client, { + get(target, methodName: string) { + const originalMethod = target[methodName] + + if (typeof originalMethod !== 'function') { + return originalMethod + } + + return async function (options: any = {}) { + try { + if (transformer) { + options = await Promise.resolve(transformer(props, methodName, options)) + } + + return await originalMethod.call(target, options) + } catch (error) { + onError?.(methodName, error, options) + throw error + } + } + } + }) +} diff --git a/packages/template-retail-react-app/CHANGELOG.md b/packages/template-retail-react-app/CHANGELOG.md index e95f90eacf..d030e718c8 100644 --- a/packages/template-retail-react-app/CHANGELOG.md +++ b/packages/template-retail-react-app/CHANGELOG.md @@ -2,7 +2,6 @@ - Improved the layout of product tiles in product scroll and product list [#2446](https://github.com/SalesforceCommerceCloud/pwa-kit/pull/2446) - Updated 6 new languagues [#2495](https://github.com/SalesforceCommerceCloud/pwa-kit/pull/2495) -- Show Bonus Product Label on OrderSummary component [#2524](https://github.com/SalesforceCommerceCloud/pwa-kit/pull/2524) ## v6.1.0 (May 22, 2025) diff --git a/packages/template-retail-react-app/app/components/_app-config/index.jsx b/packages/template-retail-react-app/app/components/_app-config/index.jsx index e28be6db6a..242c95a60e 100644 --- a/packages/template-retail-react-app/app/components/_app-config/index.jsx +++ b/packages/template-retail-react-app/app/components/_app-config/index.jsx @@ -21,7 +21,7 @@ import {ChakraProvider} from '@salesforce/retail-react-app/app/components/shared import 'focus-visible/dist/focus-visible' import theme from '@salesforce/retail-react-app/app/theme' -import {MultiSiteProvider} from '@salesforce/retail-react-app/app/contexts' +import {MultiSiteProvider, StoreLocatorProvider} from '@salesforce/retail-react-app/app/contexts' import {useAppOrigin} from '@salesforce/retail-react-app/app/hooks/use-app-origin' import { resolveSiteFromUrl, @@ -35,7 +35,17 @@ import {CommerceApiProvider} from '@salesforce/commerce-sdk-react' import {withReactQuery} from '@salesforce/pwa-kit-react-sdk/ssr/universal/components/with-react-query' import {useCorrelationId} from '@salesforce/pwa-kit-react-sdk/ssr/universal/hooks' import {ReactQueryDevtools} from '@tanstack/react-query-devtools' -import {DEFAULT_DNT_STATE} from '@salesforce/retail-react-app/app/constants' +import { + DEFAULT_DNT_STATE, + STORE_LOCATOR_RADIUS, + STORE_LOCATOR_RADIUS_UNIT, + STORE_LOCATOR_DEFAULT_COUNTRY, + STORE_LOCATOR_DEFAULT_COUNTRY_CODE, + STORE_LOCATOR_DEFAULT_POSTAL_CODE, + STORE_LOCATOR_DEFAULT_PAGE_SIZE, + STORE_LOCATOR_SUPPORTED_COUNTRIES +} from '@salesforce/retail-react-app/app/constants' + /** * Use the AppConfig component to inject extra arguments into the getProps * methods for all Route Components in the app – typically you'd want to do this @@ -56,6 +66,16 @@ const AppConfig = ({children, locals = {}}) => { const passwordlessCallback = locals.appConfig.login?.passwordless?.callbackURI + const storeLocatorConfig = { + radius: STORE_LOCATOR_RADIUS, + radiusUnit: STORE_LOCATOR_RADIUS_UNIT, + defaultCountry: STORE_LOCATOR_DEFAULT_COUNTRY, + defaultCountryCode: STORE_LOCATOR_DEFAULT_COUNTRY_CODE, + defaultPostalCode: STORE_LOCATOR_DEFAULT_POSTAL_CODE, + defaultPageSize: STORE_LOCATOR_DEFAULT_PAGE_SIZE, + supportedCountries: STORE_LOCATOR_SUPPORTED_COUNTRIES + } + return ( { logger={createLogger({packageName: 'commerce-sdk-react'})} > - {children} + + {children} + diff --git a/packages/template-retail-react-app/app/components/_app/index.jsx b/packages/template-retail-react-app/app/components/_app/index.jsx index a841ef4930..6745dfb92e 100644 --- a/packages/template-retail-react-app/app/components/_app/index.jsx +++ b/packages/template-retail-react-app/app/components/_app/index.jsx @@ -46,7 +46,7 @@ import {DrawerMenu} from '@salesforce/retail-react-app/app/components/drawer-men import {ListMenu, ListMenuContent} from '@salesforce/retail-react-app/app/components/list-menu' import {HideOnDesktop, HideOnMobile} from '@salesforce/retail-react-app/app/components/responsive' import AboveHeader from '@salesforce/retail-react-app/app/components/_app/partials/above-header' -import StoreLocatorModal from '@salesforce/retail-react-app/app/components/store-locator-modal' +import {StoreLocatorModal} from '@salesforce/retail-react-app/app/components/store-locator' // Hooks import {AuthModal, useAuthModal} from '@salesforce/retail-react-app/app/hooks/use-auth-modal' import { diff --git a/packages/template-retail-react-app/app/components/item-variant/item-attributes.jsx b/packages/template-retail-react-app/app/components/item-variant/item-attributes.jsx index 535953060d..15ee4ec9c6 100644 --- a/packages/template-retail-react-app/app/components/item-variant/item-attributes.jsx +++ b/packages/template-retail-react-app/app/components/item-variant/item-attributes.jsx @@ -27,7 +27,6 @@ const ItemAttributes = ({includeQuantity, currency, ...props}) => { const promotionIds = variant.priceAdjustments?.map((adj) => adj.promotionId) ?? [] const intl = useIntl() - const isBonusProduct = variant?.bonusProductLineItem // Fetch all the promotions given by price adjustments. We display this info in // the promotion info popover when applicable. const {data: res} = usePromotions( @@ -92,15 +91,6 @@ const ItemAttributes = ({includeQuantity, currency, ...props}) => { return ( - {isBonusProduct && ( - - - - )} - {variationValues && Object.keys(variationValues).map((key) => ( { }) }) }) - -test('renders Bonus Product when isBonusProduct is true', async () => { - const mockVariantWithBonusProduct = { - ...mockBundledProductItemsVariant, - bonusProductLineItem: true // Simulate the bonus product flag - } - - renderWithProviders() - - await waitFor(() => { - expect(screen.getByText(/Bonus Product/i)).toBeInTheDocument() - }) -}) - -test('does not render Bonus Product when isBonusProduct is false', async () => { - const mockVariantWithoutBonusProduct = { - ...mockBundledProductItemsVariant, - bonusProductLineItem: false // Simulate the absence of the bonus product flag - } - - renderWithProviders() - - await waitFor(() => { - expect(screen.queryByText(/Bonus Product/i)).not.toBeInTheDocument() - }) -}) - -test('does not render Bonus Product when bonusProductLineItem is undefined', async () => { - const mockVariantWithoutBonusProduct = {...mockBundledProductItemsVariant} - delete mockVariantWithoutBonusProduct.bonusProductLineItem - - renderWithProviders() - await waitFor(() => { - expect(screen.queryByText(/Bonus Product/i)).not.toBeInTheDocument() - }) -}) diff --git a/packages/template-retail-react-app/app/components/locale-text/index.jsx b/packages/template-retail-react-app/app/components/locale-text/index.jsx index cc5789d127..cc447264f4 100644 --- a/packages/template-retail-react-app/app/components/locale-text/index.jsx +++ b/packages/template-retail-react-app/app/components/locale-text/index.jsx @@ -40,7 +40,7 @@ LocaleText.propTypes = { export default LocaleText /** - * Translations for names of the commonly-used locales. + * Translations for names of the commonly used locales. * `locale` parameter format for OCAPI and Commerce API: - * https://documentation.b2c.commercecloud.salesforce.com/DOC1/topic/com.demandware.dochelp/OCAPI/current/usage/Localization.html */ diff --git a/packages/template-retail-react-app/app/components/product-view/index.test.js b/packages/template-retail-react-app/app/components/product-view/index.test.js index b4d1df55ed..ab5e712760 100644 --- a/packages/template-retail-react-app/app/components/product-view/index.test.js +++ b/packages/template-retail-react-app/app/components/product-view/index.test.js @@ -15,6 +15,7 @@ import ProductView from '@salesforce/retail-react-app/app/components/product-vie import {renderWithProviders} from '@salesforce/retail-react-app/app/utils/test-utils' import userEvent from '@testing-library/user-event' import {useCurrentCustomer} from '@salesforce/retail-react-app/app/hooks/use-current-customer' +import frMessages from '@salesforce/retail-react-app/app/static/translations/compiled/fr-FR.json' const MockComponent = (props) => { const {data: customer} = useCurrentCustomer() @@ -346,3 +347,25 @@ test('renders a product bundle properly - child item', () => { expect(addToWishlistButton).toBeNull() expect(quantityPicker).toBeNull() }) + +test('renders "Add to Cart" and "Add to Wishlist" buttons in French', async () => { + const addToCart = jest.fn() + const addToWishlist = jest.fn() + renderWithProviders( + , + { + wrapperProps: {locale: {id: 'fr-FR'}, messages: frMessages} + } + ) + + const titles = await screen.findAllByText(/Black Single Pleat Athletic Fit Wool Suit/i) + expect(titles.length).toBeGreaterThan(0) + expect(screen.getByRole('button', {name: /ajouter au panier/i})).toBeInTheDocument() + expect( + screen.getByRole('button', {name: /ajouter à la liste de souhaits/i}) + ).toBeInTheDocument() +}) diff --git a/packages/template-retail-react-app/app/components/store-locator-modal/index.jsx b/packages/template-retail-react-app/app/components/store-locator-modal/index.jsx deleted file mode 100644 index 8bb5920cbb..0000000000 --- a/packages/template-retail-react-app/app/components/store-locator-modal/index.jsx +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright (c) 2021, salesforce.com, inc. - * All rights reserved. - * SPDX-License-Identifier: BSD-3-Clause - * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause - */ - -import React, {useState, createContext} from 'react' -import PropTypes from 'prop-types' - -// Components -import { - Modal, - ModalBody, - ModalCloseButton, - ModalContent, - useBreakpointValue -} from '@salesforce/retail-react-app/app/components/shared/ui' -import StoreLocatorContent from '@salesforce/retail-react-app/app/components/store-locator-modal/store-locator-content' - -// Others -import { - DEFAULT_STORE_LOCATOR_COUNTRY, - DEFAULT_STORE_LOCATOR_POSTAL_CODE, - STORE_LOCATOR_NUM_STORES_PER_LOAD -} from '@salesforce/retail-react-app/app/constants' - -export const StoreLocatorContext = createContext() -export const useStoreLocator = () => { - const [userHasSetManualGeolocation, setUserHasSetManualGeolocation] = useState(false) - const [automaticGeolocationHasFailed, setAutomaticGeolocationHasFailed] = useState(false) - const [userWantsToShareLocation, setUserWantsToShareLocation] = useState(false) - - const [searchStoresParams, setSearchStoresParams] = useState({ - countryCode: DEFAULT_STORE_LOCATOR_COUNTRY.countryCode, - postalCode: DEFAULT_STORE_LOCATOR_POSTAL_CODE, - limit: STORE_LOCATOR_NUM_STORES_PER_LOAD - }) - - return { - userHasSetManualGeolocation, - setUserHasSetManualGeolocation, - automaticGeolocationHasFailed, - setAutomaticGeolocationHasFailed, - userWantsToShareLocation, - setUserWantsToShareLocation, - searchStoresParams, - setSearchStoresParams - } -} - -const StoreLocatorModal = ({isOpen, onClose}) => { - const storeLocator = useStoreLocator() - const isDesktopView = useBreakpointValue({base: false, lg: true}) - - return ( - - {isDesktopView ? ( - - - - - - - - - ) : ( - - - - - - - - - )} - - ) -} - -StoreLocatorModal.propTypes = { - isOpen: PropTypes.bool, - onClose: PropTypes.func -} - -export default StoreLocatorModal diff --git a/packages/template-retail-react-app/app/components/store-locator-modal/index.test.jsx b/packages/template-retail-react-app/app/components/store-locator-modal/index.test.jsx deleted file mode 100644 index 2fadf4cb89..0000000000 --- a/packages/template-retail-react-app/app/components/store-locator-modal/index.test.jsx +++ /dev/null @@ -1,212 +0,0 @@ -/* - * Copyright (c) 2021, salesforce.com, inc. - * All rights reserved. - * SPDX-License-Identifier: BSD-3-Clause - * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause - */ - -import React from 'react' -import StoreLocatorModal from '@salesforce/retail-react-app/app/components/store-locator-modal/index' -import {renderWithProviders} from '@salesforce/retail-react-app/app/utils/test-utils' -import {rest} from 'msw' - -const mockStoresData = [ - { - address1: '162 University Ave', - city: 'Palo Alto', - countryCode: 'US', - distance: 0.0, - distanceUnit: 'km', - id: '00041', - latitude: 37.189396, - longitude: -121.705327, - name: 'Palo Alto Store', - posEnabled: false, - postalCode: '94301', - stateCode: 'CA', - storeHours: 'THIS IS ENGLISH STORE HOURS', - storeLocatorEnabled: true, - c_countryCodeValue: 'US' - }, - { - address1: 'Holstenstraße 1', - city: 'Kiel', - countryCode: 'DE', - distance: 8847.61, - distanceUnit: 'km', - id: '00031', - inventoryId: 'inventory_m_store_store23', - latitude: 54.3233, - longitude: 10.1394, - name: 'Kiel Electronics Store', - phone: '+49 431 123456', - posEnabled: false, - postalCode: '24103', - storeHours: - 'Monday 9 AM–7 PM\nTuesday 9 AM–7 PM\nWednesday 9 AM–7 PM\nThursday 9 AM–8 PM\nFriday 9 AM–7 PM\nSaturday 9 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Heiligengeiststraße 2', - city: 'Oldenburg', - countryCode: 'DE', - distance: 8873.75, - distanceUnit: 'km', - id: '00036', - inventoryId: 'inventory_m_store_store28', - latitude: 53.1445, - longitude: 8.2146, - name: 'Oldenburg Tech Depot', - phone: '+49 441 876543', - posEnabled: false, - postalCode: '26121', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Obernstraße 2', - city: 'Bremen', - countryCode: 'DE', - distance: 8904.18, - distanceUnit: 'km', - id: '00011', - inventoryId: 'inventory_m_store_store2', - latitude: 53.0765, - longitude: 8.8085, - name: 'Bremen Tech Store', - phone: '+49 421 234567', - posEnabled: false, - postalCode: '28195', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Sögestraße 40', - city: 'Bremen', - countryCode: 'DE', - distance: 8904.19, - distanceUnit: 'km', - id: '00026', - inventoryId: 'inventory_m_store_store18', - latitude: 53.0758, - longitude: 8.8072, - name: 'Bremen Tech World', - phone: '+49 421 567890', - posEnabled: false, - postalCode: '28195', - storeHours: - 'Monday 9 AM–8 PM\nTuesday 9 AM–8 PM\nWednesday 9 AM–8 PM\nThursday 9 AM–9 PM\nFriday 9 AM–8 PM\nSaturday 9 AM–7 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Jungfernstieg 12', - city: 'Hamburg', - countryCode: 'DE', - distance: 8910.05, - distanceUnit: 'km', - id: '00005', - inventoryId: 'inventory_m_store_store5', - latitude: 53.553405, - longitude: 9.992196, - name: 'Hamburg Electronics Outlet', - phone: '+49 40 444444444', - posEnabled: false, - postalCode: '20354', - storeHours: - 'Monday 10 AM–8 PM\nTuesday 10 AM–8 PM\nWednesday 10 AM–8 PM\nThursday 10 AM–9 PM\nFriday 10 AM–8 PM\nSaturday 10 AM–7 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Große Straße 40', - city: 'Osnabrück', - countryCode: 'DE', - distance: 8942.1, - distanceUnit: 'km', - id: '00037', - inventoryId: 'inventory_m_store_store29', - latitude: 52.2799, - longitude: 8.0472, - name: 'Osnabrück Tech Mart', - phone: '+49 541 654321', - posEnabled: false, - postalCode: '49074', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Kröpeliner Straße 48', - city: 'Rostock', - countryCode: 'DE', - distance: 8945.47, - distanceUnit: 'km', - id: '00032', - inventoryId: 'inventory_m_store_store24', - latitude: 54.0899, - longitude: 12.1349, - name: 'Rostock Tech Store', - phone: '+49 381 234567', - posEnabled: false, - postalCode: '18055', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Kennedyplatz 7', - city: 'Essen', - countryCode: 'DE', - distance: 8969.09, - distanceUnit: 'km', - id: '00013', - inventoryId: 'inventory_m_store_store4', - latitude: 51.4566, - longitude: 7.0125, - name: 'Essen Electronics Depot', - phone: '+49 201 456789', - posEnabled: false, - postalCode: '45127', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Kettwiger Straße 17', - city: 'Essen', - countryCode: 'DE', - distance: 8969.13, - distanceUnit: 'km', - id: '00030', - inventoryId: 'inventory_m_store_store22', - latitude: 51.4556, - longitude: 7.0116, - name: 'Essen Tech Hub', - phone: '+49 201 654321', - posEnabled: false, - postalCode: '45127', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - } -] -const mockStores = { - limit: 10, - data: mockStoresData, - offset: 0, - total: 30 -} - -describe('StoreLocatorModal', () => { - test('renders without crashing', () => { - global.server.use( - rest.get('*/shopper-stores/v1/organizations/*', (req, res, ctx) => { - return res(ctx.delay(0), ctx.status(200), ctx.json(mockStores)) - }) - ) - expect(() => { - renderWithProviders() - }).not.toThrow() - }) -}) diff --git a/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-content.jsx b/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-content.jsx deleted file mode 100644 index 10bf5b80f2..0000000000 --- a/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-content.jsx +++ /dev/null @@ -1,213 +0,0 @@ -/* - * Copyright (c) 2021, salesforce.com, inc. - * All rights reserved. - * SPDX-License-Identifier: BSD-3-Clause - * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause - */ - -import React, {useState, useContext} from 'react' -import {useIntl} from 'react-intl' - -// Components -import { - Heading, - Accordion, - AccordionItem, - Box, - Button -} from '@salesforce/retail-react-app/app/components/shared/ui' -import StoresList from '@salesforce/retail-react-app/app/components/store-locator-modal/stores-list' -import StoreLocatorInput from '@salesforce/retail-react-app/app/components/store-locator-modal/store-locator-input' - -// Others -import { - SUPPORTED_STORE_LOCATOR_COUNTRIES, - DEFAULT_STORE_LOCATOR_COUNTRY, - STORE_LOCATOR_DISTANCE, - STORE_LOCATOR_NUM_STORES_PER_LOAD, - STORE_LOCATOR_DISTANCE_UNIT -} from '@salesforce/retail-react-app/app/constants' - -//This is an API limit and is therefore not configurable -const NUM_STORES_PER_REQUEST_API_MAX = 200 - -// Hooks -import {useSearchStores} from '@salesforce/commerce-sdk-react' -import {useForm} from 'react-hook-form' - -import {StoreLocatorContext} from '@salesforce/retail-react-app/app/components/store-locator-modal/index' - -const StoreLocatorContent = () => { - const { - searchStoresParams, - setSearchStoresParams, - userHasSetManualGeolocation, - setUserHasSetManualGeolocation - } = useContext(StoreLocatorContext) - const {countryCode, postalCode, latitude, longitude, limit} = searchStoresParams - const intl = useIntl() - const form = useForm({ - mode: 'onChange', - reValidateMode: 'onChange', - defaultValues: { - countryCode: userHasSetManualGeolocation ? countryCode : '', - postalCode: userHasSetManualGeolocation ? postalCode : '' - } - }) - - const [numStoresToShow, setNumStoresToShow] = useState(limit) - // Either the countryCode & postalCode or latitude & longitude are defined, never both - const { - data: searchStoresData, - isLoading, - refetch, - isFetching - } = useSearchStores({ - parameters: { - countryCode: countryCode, - postalCode: postalCode, - latitude: latitude, - longitude: longitude, - locale: intl.locale, - maxDistance: STORE_LOCATOR_DISTANCE, - limit: NUM_STORES_PER_REQUEST_API_MAX, - distanceUnit: STORE_LOCATOR_DISTANCE_UNIT - } - }) - - const storesInfo = - isLoading || isFetching - ? undefined - : searchStoresData?.data?.slice(0, numStoresToShow) || [] - const numStores = searchStoresData?.total || 0 - - const submitForm = async (formData) => { - const {postalCode, countryCode} = formData - if (postalCode !== '') { - if (countryCode !== '') { - setSearchStoresParams({ - postalCode: postalCode, - countryCode: countryCode, - limit: STORE_LOCATOR_NUM_STORES_PER_LOAD - }) - setUserHasSetManualGeolocation(true) - } else { - if (SUPPORTED_STORE_LOCATOR_COUNTRIES.length === 0) { - setSearchStoresParams({ - postalCode: postalCode, - countryCode: DEFAULT_STORE_LOCATOR_COUNTRY.countryCode, - limit: STORE_LOCATOR_NUM_STORES_PER_LOAD - }) - setUserHasSetManualGeolocation(true) - } - } - } - // Reset the number of stores in the UI - setNumStoresToShow(STORE_LOCATOR_NUM_STORES_PER_LOAD) - - // Ensures API call is made regardless of caching to provide UX feedback on click - refetch() - } - - const displayStoreLocatorStatusMessage = () => { - if (storesInfo === undefined) - return intl.formatMessage({ - id: 'store_locator.description.loading_locations', - defaultMessage: 'Loading locations...' - }) - if (storesInfo.length === 0) - return intl.formatMessage({ - id: 'store_locator.description.no_locations', - defaultMessage: 'Sorry, there are no locations in this area' - }) - if (searchStoresParams.postalCode !== undefined) - return `${intl.formatMessage( - { - id: 'store_locator.description.viewing_near_postal_code', - defaultMessage: - 'Viewing stores within {distance}{distanceUnit} of {postalCode} in ' - }, - { - distance: STORE_LOCATOR_DISTANCE, - distanceUnit: STORE_LOCATOR_DISTANCE_UNIT, - postalCode: searchStoresParams.postalCode - } - )} - ${ - SUPPORTED_STORE_LOCATOR_COUNTRIES.length !== 0 - ? intl.formatMessage( - SUPPORTED_STORE_LOCATOR_COUNTRIES.find( - (o) => o.countryCode === searchStoresParams.countryCode - ).countryName - ) - : intl.formatMessage(DEFAULT_STORE_LOCATOR_COUNTRY.countryName) - }` - else - return intl.formatMessage({ - id: 'store_locator.description.viewing_near_your_location', - defaultMessage: 'Viewing stores near your location' - }) - } - - return ( - <> - - {intl.formatMessage({ - id: 'store_locator.title', - defaultMessage: 'Find a Store' - })} - - - - {/* Details */} - - - {displayStoreLocatorStatusMessage()} - - - - - {!isFetching && - numStoresToShow < numStores && - numStoresToShow < NUM_STORES_PER_REQUEST_API_MAX ? ( - - - - ) : ( - '' - )} - - ) -} - -StoreLocatorContent.propTypes = {} - -export default StoreLocatorContent diff --git a/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-content.test.jsx b/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-content.test.jsx deleted file mode 100644 index 38e8c8458c..0000000000 --- a/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-content.test.jsx +++ /dev/null @@ -1,399 +0,0 @@ -/* - * Copyright (c) 2021, salesforce.com, inc. - * All rights reserved. - * SPDX-License-Identifier: BSD-3-Clause - * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause - */ - -import React, {useEffect} from 'react' -import StoreLocatorContent from '@salesforce/retail-react-app/app/components/store-locator-modal/store-locator-content' -import {renderWithProviders} from '@salesforce/retail-react-app/app/utils/test-utils' -import {waitFor, screen} from '@testing-library/react' -import PropTypes from 'prop-types' -import {STORE_LOCATOR_NUM_STORES_PER_LOAD} from '@salesforce/retail-react-app/app/constants' -import {rest} from 'msw' -import {StoreLocatorContext} from '@salesforce/retail-react-app/app/components/store-locator-modal/index' -import {useStoreLocator} from '@salesforce/retail-react-app/app/components/store-locator-modal/index' -const mockStoresData = [ - { - address1: '162 University Ave', - city: 'Palo Alto', - countryCode: 'US', - distance: 0.0, - distanceUnit: 'km', - id: '00041', - latitude: 37.189396, - longitude: -121.705327, - name: 'Palo Alto Store', - posEnabled: false, - postalCode: '94301', - stateCode: 'CA', - storeHours: 'THIS IS ENGLISH STORE HOURS', - storeLocatorEnabled: true, - c_countryCodeValue: 'US' - }, - { - address1: 'Holstenstraße 1', - city: 'Kiel', - countryCode: 'DE', - distance: 8847.61, - distanceUnit: 'km', - id: '00031', - inventoryId: 'inventory_m_store_store23', - latitude: 54.3233, - longitude: 10.1394, - name: 'Kiel Electronics Store', - phone: '+49 431 123456', - posEnabled: false, - postalCode: '24103', - storeHours: - 'Monday 9 AM–7 PM\nTuesday 9 AM–7 PM\nWednesday 9 AM–7 PM\nThursday 9 AM–8 PM\nFriday 9 AM–7 PM\nSaturday 9 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Heiligengeiststraße 2', - city: 'Oldenburg', - countryCode: 'DE', - distance: 8873.75, - distanceUnit: 'km', - id: '00036', - inventoryId: 'inventory_m_store_store28', - latitude: 53.1445, - longitude: 8.2146, - name: 'Oldenburg Tech Depot', - phone: '+49 441 876543', - posEnabled: false, - postalCode: '26121', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Obernstraße 2', - city: 'Bremen', - countryCode: 'DE', - distance: 8904.18, - distanceUnit: 'km', - id: '00011', - inventoryId: 'inventory_m_store_store2', - latitude: 53.0765, - longitude: 8.8085, - name: 'Bremen Tech Store', - phone: '+49 421 234567', - posEnabled: false, - postalCode: '28195', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Sögestraße 40', - city: 'Bremen', - countryCode: 'DE', - distance: 8904.19, - distanceUnit: 'km', - id: '00026', - inventoryId: 'inventory_m_store_store18', - latitude: 53.0758, - longitude: 8.8072, - name: 'Bremen Tech World', - phone: '+49 421 567890', - posEnabled: false, - postalCode: '28195', - storeHours: - 'Monday 9 AM–8 PM\nTuesday 9 AM–8 PM\nWednesday 9 AM–8 PM\nThursday 9 AM–9 PM\nFriday 9 AM–8 PM\nSaturday 9 AM–7 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Jungfernstieg 12', - city: 'Hamburg', - countryCode: 'DE', - distance: 8910.05, - distanceUnit: 'km', - id: '00005', - inventoryId: 'inventory_m_store_store5', - latitude: 53.553405, - longitude: 9.992196, - name: 'Hamburg Electronics Outlet', - phone: '+49 40 444444444', - posEnabled: false, - postalCode: '20354', - storeHours: - 'Monday 10 AM–8 PM\nTuesday 10 AM–8 PM\nWednesday 10 AM–8 PM\nThursday 10 AM–9 PM\nFriday 10 AM–8 PM\nSaturday 10 AM–7 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Große Straße 40', - city: 'Osnabrück', - countryCode: 'DE', - distance: 8942.1, - distanceUnit: 'km', - id: '00037', - inventoryId: 'inventory_m_store_store29', - latitude: 52.2799, - longitude: 8.0472, - name: 'Osnabrück Tech Mart', - phone: '+49 541 654321', - posEnabled: false, - postalCode: '49074', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Kröpeliner Straße 48', - city: 'Rostock', - countryCode: 'DE', - distance: 8945.47, - distanceUnit: 'km', - id: '00032', - inventoryId: 'inventory_m_store_store24', - latitude: 54.0899, - longitude: 12.1349, - name: 'Rostock Tech Store', - phone: '+49 381 234567', - posEnabled: false, - postalCode: '18055', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Kennedyplatz 7', - city: 'Essen', - countryCode: 'DE', - distance: 8969.09, - distanceUnit: 'km', - id: '00013', - inventoryId: 'inventory_m_store_store4', - latitude: 51.4566, - longitude: 7.0125, - name: 'Essen Electronics Depot', - phone: '+49 201 456789', - posEnabled: false, - postalCode: '45127', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Kettwiger Straße 17', - city: 'Essen', - countryCode: 'DE', - distance: 8969.13, - distanceUnit: 'km', - id: '00030', - inventoryId: 'inventory_m_store_store22', - latitude: 51.4556, - longitude: 7.0116, - name: 'Essen Tech Hub', - phone: '+49 201 654321', - posEnabled: false, - postalCode: '45127', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - } -] -const mockStoresTotalIsHigherThanLimit = { - limit: 10, - data: mockStoresData, - offset: 0, - total: 30 -} - -const mockStoresTotalIsEqualToLimit = { - limit: 10, - data: mockStoresData, - offset: 0, - total: 10 -} - -const mockNoStores = { - limit: 0, - total: 0 -} - -const WrapperComponent = ({searchStoresParams, userHasSetManualGeolocation}) => { - const storeLocator = useStoreLocator() - useEffect(() => { - storeLocator.setSearchStoresParams(searchStoresParams) - storeLocator.setUserHasSetManualGeolocation(userHasSetManualGeolocation) - }, []) - return ( - - - - ) -} -WrapperComponent.propTypes = { - storesInfo: PropTypes.array, - userHasSetManualGeolocation: PropTypes.bool, - searchStoresParams: PropTypes.object -} - -describe('StoreLocatorContent', () => { - test('renders without crashing', () => { - global.server.use( - rest.get('*/shopper-stores/v1/organizations/*', (req, res, ctx) => { - return res( - ctx.delay(0), - ctx.status(200), - ctx.json(mockStoresTotalIsHigherThanLimit) - ) - }) - ) - expect(() => { - renderWithProviders( - - ) - }).not.toThrow() - }) - - test('Expected information exists', async () => { - global.server.use( - rest.get('*/shopper-stores/v1/organizations/*', (req, res, ctx) => { - return res( - ctx.delay(0), - ctx.status(200), - ctx.json(mockStoresTotalIsHigherThanLimit) - ) - }) - ) - renderWithProviders( - - ) - - await waitFor(async () => { - const findButton = screen.getByRole('button', {name: /Find/i}) - const useMyLocationButton = screen.getByRole('button', {name: /Use My Location/i}) - const descriptionFindAStore = screen.getByText(/Find a Store/i) - const viewing = screen.getByText(/Viewing stores within 100km of 10178 in Germany/i) - - expect(findButton).toBeInTheDocument() - expect(useMyLocationButton).toBeInTheDocument() - expect(descriptionFindAStore).toBeInTheDocument() - expect(viewing).toBeInTheDocument() - }) - }) - - test('No stores text exists', async () => { - global.server.use( - rest.get('*/shopper-stores/v1/organizations/*', (req, res, ctx) => { - return res(ctx.delay(0), ctx.status(200), ctx.json(mockNoStores)) - }) - ) - renderWithProviders( - - ) - - await waitFor(async () => { - const noLocations = screen.getByText(/Sorry, there are no locations in this area/i) - - expect(noLocations).toBeInTheDocument() - }) - }) - - test('Near your location text exists', async () => { - global.server.use( - rest.get('*/shopper-stores/v1/organizations/*', (req, res, ctx) => { - return res( - ctx.delay(0), - ctx.status(200), - ctx.json(mockStoresTotalIsHigherThanLimit) - ) - }) - ) - - renderWithProviders( - - ) - - await waitFor(async () => { - const nearYourLocation = screen.getByText(/Viewing stores near your location/i) - - expect(nearYourLocation).toBeInTheDocument() - }) - }) - - test('Load More button exists when total stores is higher than display limit', async () => { - global.server.use( - rest.get('*/shopper-stores/v1/organizations/*', (req, res, ctx) => { - return res( - ctx.delay(0), - ctx.status(200), - ctx.json(mockStoresTotalIsHigherThanLimit) - ) - }) - ) - - renderWithProviders( - - ) - await waitFor(async () => { - const findButton = screen.getByRole('button', {name: /Find/i}) - const aStore = screen.getByText(/162 University Ave/i) - const loadMore = screen.getByText(/Load More/i) - expect(findButton).toBeInTheDocument() - expect(aStore).toBeInTheDocument() - expect(loadMore).toBeInTheDocument() - }) - }) - - test('Load More button doesnt exist when total stores is equal to display limit', async () => { - global.server.use( - rest.get('*/shopper-stores/v1/organizations/*', (req, res, ctx) => { - return res(ctx.delay(0), ctx.status(200), ctx.json(mockStoresTotalIsEqualToLimit)) - }) - ) - renderWithProviders( - - ) - await waitFor(() => { - const loadMore = screen.queryByText(/Load More/i) - expect(loadMore).not.toBeInTheDocument() - }) - }) -}) diff --git a/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-input.jsx b/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-input.jsx deleted file mode 100644 index c7c4bc6321..0000000000 --- a/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-input.jsx +++ /dev/null @@ -1,230 +0,0 @@ -/* - * Copyright (c) 2021, salesforce.com, inc. - * All rights reserved. - * SPDX-License-Identifier: BSD-3-Clause - * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause - */ - -import React, {useEffect, useContext} from 'react' -import {useIntl} from 'react-intl' -import PropTypes from 'prop-types' - -// Components -import { - Button, - InputGroup, - Select, - Box, - Input, - FormControl, - FormErrorMessage -} from '@salesforce/retail-react-app/app/components/shared/ui' -import {AlertIcon} from '@salesforce/retail-react-app/app/components/icons' -import {Controller} from 'react-hook-form' - -// Others -import { - SUPPORTED_STORE_LOCATOR_COUNTRIES, - STORE_LOCATOR_NUM_STORES_PER_LOAD -} from '@salesforce/retail-react-app/app/constants' -import {StoreLocatorContext} from '@salesforce/retail-react-app/app/components/store-locator-modal/index' - -const useGeolocation = () => { - const { - setSearchStoresParams, - setAutomaticGeolocationHasFailed, - setUserHasSetManualGeolocation, - userHasSetManualGeolocation - } = useContext(StoreLocatorContext) - - const getGeolocationError = () => { - setAutomaticGeolocationHasFailed(true) - } - const getGeolocationSuccess = (position) => { - setAutomaticGeolocationHasFailed(false) - setSearchStoresParams({ - latitude: position.coords.latitude, - longitude: position.coords.longitude, - limit: STORE_LOCATOR_NUM_STORES_PER_LOAD - }) - } - - const getUserGeolocation = () => { - if (navigator?.geolocation) { - navigator.geolocation.getCurrentPosition(getGeolocationSuccess, getGeolocationError) - setUserHasSetManualGeolocation(false) - } else { - console.log('Geolocation not supported') - } - } - - useEffect(() => { - if (!userHasSetManualGeolocation) getUserGeolocation() - }, []) - - return getUserGeolocation -} - -const StoreLocatorInput = ({form, submitForm}) => { - const { - searchStoresParams, - userHasSetManualGeolocation, - automaticGeolocationHasFailed, - setUserWantsToShareLocation, - userWantsToShareLocation - } = useContext(StoreLocatorContext) - - const getUserGeolocation = useGeolocation() - const {control} = form - const intl = useIntl() - return ( -
- - {SUPPORTED_STORE_LOCATOR_COUNTRIES.length > 0 && ( - { - return SUPPORTED_STORE_LOCATOR_COUNTRIES.length !== 0 ? ( - - - {form.formState.errors.countryCode && ( - - - )} - - ) : ( - <> - ) - }} - > - )} - - - { - return ( - - - {form.formState.errors.postalCode && ( - - - )} - - ) - }} - > - - - - {intl.formatMessage({ - id: 'store_locator.description.or', - defaultMessage: 'Or' - })} - - - - - - -
- ) -} - -StoreLocatorInput.propTypes = { - form: PropTypes.object, - submitForm: PropTypes.func -} - -export default StoreLocatorInput diff --git a/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-input.test.jsx b/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-input.test.jsx deleted file mode 100644 index 03d1c6880b..0000000000 --- a/packages/template-retail-react-app/app/components/store-locator-modal/store-locator-input.test.jsx +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Copyright (c) 2021, salesforce.com, inc. - * All rights reserved. - * SPDX-License-Identifier: BSD-3-Clause - * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause - */ - -import React, {useEffect} from 'react' -import StoreLocatorInput from '@salesforce/retail-react-app/app/components/store-locator-modal/store-locator-input' -import {renderWithProviders} from '@salesforce/retail-react-app/app/utils/test-utils' -import {waitFor, screen} from '@testing-library/react' -import {useForm} from 'react-hook-form' -import PropTypes from 'prop-types' -import {StoreLocatorContext} from '@salesforce/retail-react-app/app/components/store-locator-modal/index' -import {useStoreLocator} from '@salesforce/retail-react-app/app/components/store-locator-modal/index' -import {STORE_LOCATOR_NUM_STORES_PER_LOAD} from '@salesforce/retail-react-app/app/constants' - -const WrapperComponent = ({userHasSetManualGeolocation}) => { - const form = useForm({ - mode: 'onChange', - reValidateMode: 'onChange', - defaultValues: { - countryCode: 'DE', - postalCode: '10178' - } - }) - const storeLocator = useStoreLocator() - useEffect(() => { - storeLocator.setUserHasSetManualGeolocation(userHasSetManualGeolocation) - storeLocator.setSearchStoresParams({ - postalCode: '10178', - countryCode: 'DE', - limit: STORE_LOCATOR_NUM_STORES_PER_LOAD - }) - }, []) - - return ( - - - - ) -} -WrapperComponent.propTypes = { - storesInfo: PropTypes.array, - userHasSetManualGeolocation: PropTypes.bool, - getUserGeolocation: PropTypes.func -} - -describe('StoreLocatorInput', () => { - afterEach(() => { - jest.clearAllMocks() - jest.resetModules() - }) - test('Renders without crashing', () => { - expect(() => { - renderWithProviders( - - ) - }).not.toThrow() - }) - - test('Expected information exists', async () => { - renderWithProviders( - - ) - - await waitFor(async () => { - const findButton = screen.getByRole('button', {name: /Find/i}) - const useMyLocationButton = screen.getByRole('button', {name: /Use My Location/i}) - - expect(findButton).toBeInTheDocument() - expect(useMyLocationButton).toBeInTheDocument() - }) - }) -}) diff --git a/packages/template-retail-react-app/app/components/store-locator-modal/stores-list.jsx b/packages/template-retail-react-app/app/components/store-locator-modal/stores-list.jsx deleted file mode 100644 index a3fbd0a289..0000000000 --- a/packages/template-retail-react-app/app/components/store-locator-modal/stores-list.jsx +++ /dev/null @@ -1,131 +0,0 @@ -/* - * Copyright (c) 2021, salesforce.com, inc. - * All rights reserved. - * SPDX-License-Identifier: BSD-3-Clause - * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause - */ - -import React, {useEffect, useState} from 'react' -import {useIntl} from 'react-intl' -import PropTypes from 'prop-types' - -// Components -import { - AccordionItem, - AccordionButton, - AccordionIcon, - AccordionPanel, - Box, - HStack, - Radio, - RadioGroup -} from '@salesforce/retail-react-app/app/components/shared/ui' - -// Hooks -import useMultiSite from '@salesforce/retail-react-app/app/hooks/use-multi-site' - -const StoresList = ({storesInfo}) => { - const intl = useIntl() - const {site} = useMultiSite() - const storeInfoKey = `store_${site.id}` - const [selectedStore, setSelectedStore] = useState('') - - useEffect(() => { - setSelectedStore(JSON.parse(window.localStorage.getItem(storeInfoKey))?.id || '') - }, [storeInfoKey]) - - const handleChange = (storeId) => { - setSelectedStore(storeId) - const store = storesInfo.find((store) => store.id === storeId) - window.localStorage.setItem( - storeInfoKey, - JSON.stringify({ - id: storeId, - name: store.name || null, - inventoryId: store.inventoryId || null - }) - ) - } - - return ( - - {storesInfo?.map((store, index) => { - return ( - - - - - {store.name && {store.name}} - - {store.address1} - - - {store.city}, {store.stateCode ? store.stateCode : ''}{' '} - {store.postalCode} - - {store.distance !== undefined && ( - <> -
- - {store.distance} {store.distanceUnit}{' '} - {intl.formatMessage({ - id: 'store_locator.description.away', - defaultMessage: 'away' - })} - - - )} - {store.phone && ( - <> -
- - {intl.formatMessage({ - id: 'store_locator.description.phone', - defaultMessage: 'Phone:' - })}{' '} - {store.phone} - - - )} - {store.storeHours && ( - <> - {' '} - - - {intl.formatMessage({ - id: 'store_locator.action.viewMore', - defaultMessage: 'View More' - })} - - - - -
- {' '} - - )} - - - - ) - })} - - ) -} - -StoresList.propTypes = { - storesInfo: PropTypes.array -} - -export default StoresList diff --git a/packages/template-retail-react-app/app/components/store-locator-modal/stores-list.test.jsx b/packages/template-retail-react-app/app/components/store-locator-modal/stores-list.test.jsx deleted file mode 100644 index a326ef38c0..0000000000 --- a/packages/template-retail-react-app/app/components/store-locator-modal/stores-list.test.jsx +++ /dev/null @@ -1,199 +0,0 @@ -/* - * Copyright (c) 2021, salesforce.com, inc. - * All rights reserved. - * SPDX-License-Identifier: BSD-3-Clause - * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause - */ - -import React from 'react' -import StoresList from '@salesforce/retail-react-app/app/components/store-locator-modal/stores-list' -import {renderWithProviders} from '@salesforce/retail-react-app/app/utils/test-utils' -import {waitFor, screen, fireEvent} from '@testing-library/react' -import userEvent from '@testing-library/user-event' -import {Accordion} from '@salesforce/retail-react-app/app/components/shared/ui' -import mockConfig from '@salesforce/retail-react-app/config/mocks/default' - -const mockSearchStoresData = [ - { - address1: 'Kirchgasse 12', - city: 'Wiesbaden', - countryCode: 'DE', - distance: 0.74, - distanceUnit: 'km', - id: '00019', - inventoryId: 'inventory_m_store_store11', - latitude: 50.0826, - longitude: 8.24, - name: 'Wiesbaden Tech Depot', - phone: '+49 611 876543', - posEnabled: false, - postalCode: '65185', - storeHours: 'Monday 9 AM to 7 PM', - storeLocatorEnabled: true - }, - { - address1: 'Schaumainkai 63', - city: 'Frankfurt am Main', - countryCode: 'DE', - distance: 30.78, - distanceUnit: 'km', - id: '00002', - inventoryId: 'inventory_m_store_store4', - latitude: 50.097416, - longitude: 8.669059, - name: 'Frankfurt Electronics Store', - phone: '+49 69 111111111', - posEnabled: false, - postalCode: '60596', - storeHours: - 'Monday 10 AM–6 PM\nTuesday 10 AM–6 PM\nWednesday 10 AM–6 PM\nThursday 10 AM–9 PM\nFriday 10 AM–6 PM\nSaturday 10 AM–6 PM\nSunday 10 AM–6 PM', - storeLocatorEnabled: true - }, - { - address1: 'Löhrstraße 87', - city: 'Koblenz', - countryCode: 'DE', - distance: 55.25, - distanceUnit: 'km', - id: '00035', - inventoryId: 'inventory_m_store_store27', - latitude: 50.3533, - longitude: 7.5946, - name: 'Koblenz Electronics Store', - phone: '+49 261 123456', - posEnabled: false, - postalCode: '56068', - storeHours: - 'Monday 9 AM–7 PM\nTuesday 9 AM–7 PM\nWednesday 9 AM–7 PM\nThursday 9 AM–8 PM\nFriday 9 AM–7 PM\nSaturday 9 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Hauptstraße 47', - city: 'Heidelberg', - countryCode: 'DE', - distance: 81.1, - distanceUnit: 'km', - id: '00021', - latitude: 49.4077, - longitude: 8.6908, - name: 'Store with no inventoryId', - phone: '+49 6221 123456', - posEnabled: false, - postalCode: '69117', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - } -] - -describe('StoresList', () => { - test('renders without crashing', () => { - expect(() => { - renderWithProviders( - - - - ) - }).not.toThrow() - }) - - test('Expected information exists', async () => { - renderWithProviders( - - - - ) - - expect(screen.queryAllByRole('radio')).toHaveLength(mockSearchStoresData.length) - - await waitFor(async () => { - mockSearchStoresData.forEach((store) => { - const storeName = screen.getByText(store.name) - const storeAddress = screen.getByText(store.address1) - const storeCityAndPostalCode = screen.getByText( - `${store.city}, ${store.postalCode}` - ) - const storeDistance = screen.getByText( - `${store.distance} ${store.distanceUnit} away` - ) - const storePhoneNumber = screen.getByText(`Phone: ${store.phone}`) - - expect(storeName).toBeInTheDocument() - expect(storeAddress).toBeInTheDocument() - expect(storeCityAndPostalCode).toBeInTheDocument() - expect(storeDistance).toBeInTheDocument() - expect(storePhoneNumber).toBeInTheDocument() - }) - }) - }) - - test('Clicking View More opens store hours', async () => { - renderWithProviders( - - - - ) - - await waitFor(async () => { - const viewMoreButtons = screen.getAllByRole('button', {name: /View More/i}) - - // Click on the first button - await userEvent.click(viewMoreButtons[0]) - - const aStoreOpenHours = screen.getByText(/Monday\s*9\s*AM\s*to\s*7\s*PM/i) - expect(aStoreOpenHours).toBeInTheDocument() - }) - }) - - test('Is sorted by distance away', async () => { - renderWithProviders( - - - - ) - await waitFor(async () => { - const numbers = [ - screen.getByText(/\s*0\.74\s*km\s*away\s*/), - screen.getByText(/\s*30\.78\s*km\s*away\s*/), - screen.getByText(/\s*55\.25\s*km\s*away\s*/), - screen.getByText(/\s*81\.1\s*km\s*away\s*/) - ] - - // Check that the numbers are in the document - numbers.forEach((number) => { - expect(number).toBeInTheDocument() - }) - - // Check that the numbers are in the correct order - const numberTexts = numbers.map((number) => number.textContent) - expect(numberTexts).toEqual([ - '0.74 km away', - '30.78 km away', - '55.25 km away', - '81.1 km away' - ]) - // Check that the numbers are in the correct visual order - const positions = numbers.map((number) => number.getBoundingClientRect().top) - expect(positions).toEqual([...positions].sort((a, b) => a - b)) - }) - }) - - test('Can select store', async () => { - renderWithProviders( - - - - ) - - await waitFor(async () => { - const {id, name, inventoryId} = mockSearchStoresData[1] - const radioButton = screen.getByDisplayValue(id) - fireEvent.click(radioButton) - - const expectedStoreInfo = {id, name, inventoryId} - expect(localStorage.getItem(`store_${mockConfig.app.defaultSite}`)).toEqual( - JSON.stringify(expectedStoreInfo) - ) - }) - }) -}) diff --git a/packages/template-retail-react-app/app/components/store-locator/diagram.png b/packages/template-retail-react-app/app/components/store-locator/diagram.png new file mode 100644 index 0000000000..5cc09de330 Binary files /dev/null and b/packages/template-retail-react-app/app/components/store-locator/diagram.png differ diff --git a/packages/template-retail-react-app/app/components/store-locator/form.jsx b/packages/template-retail-react-app/app/components/store-locator/form.jsx new file mode 100644 index 0000000000..c4c602fafb --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/form.jsx @@ -0,0 +1,157 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React, {useEffect} from 'react' +import { + Box, + Button, + InputGroup, + Select, + FormControl, + FormErrorMessage, + Input +} from '@chakra-ui/react' +import {useForm, Controller} from 'react-hook-form' +import {useStoreLocator} from '@salesforce/retail-react-app/app/hooks/use-store-locator' +import {useGeolocation} from '@salesforce/retail-react-app/app/hooks/use-geo-location' + +export const StoreLocatorForm = () => { + const {config, formValues, setFormValues, setDeviceCoordinates} = useStoreLocator() + const {coordinates, error, refresh} = useGeolocation() + const form = useForm({ + mode: 'onChange', + reValidateMode: 'onChange', + defaultValues: { + countryCode: formValues.countryCode, + postalCode: formValues.postalCode + } + }) + const {control} = form + useEffect(() => { + if (coordinates.latitude && coordinates.longitude) { + setDeviceCoordinates(coordinates) + } + }, [coordinates]) + + const showCountrySelector = config.supportedCountries.length > 0 + + const submitForm = (formValues) => { + setFormValues(formValues) + } + + const clearForm = () => { + form.reset() + setFormValues({ + countryCode: '', + postalCode: '' + }) + } + + return ( +
{ + e.preventDefault() + void form.handleSubmit(submitForm)(e) + }} + > + + {showCountrySelector && ( + { + return ( + + + {form.formState.errors.countryCode && ( + + {form.formState.errors.countryCode.message} + + )} + + ) + }} + /> + )} + + + { + return ( + + + {form.formState.errors.postalCode && ( + + {form.formState.errors.postalCode.message} + + )} + + ) + }} + /> + + + + Or + + + + + Please agree to share your location + + +
+ ) +} diff --git a/packages/template-retail-react-app/app/components/store-locator/form.test.jsx b/packages/template-retail-react-app/app/components/store-locator/form.test.jsx new file mode 100644 index 0000000000..9382508945 --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/form.test.jsx @@ -0,0 +1,150 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React from 'react' +import {render, screen} from '@testing-library/react' +import userEvent from '@testing-library/user-event' +import {StoreLocatorForm} from '@salesforce/retail-react-app/app/components/store-locator/form' +import {useStoreLocator} from '@salesforce/retail-react-app/app/hooks/use-store-locator' +import {useGeolocation} from '@salesforce/retail-react-app/app/hooks/use-geo-location' + +jest.mock('@salesforce/retail-react-app/app/hooks/use-store-locator', () => ({ + useStoreLocator: jest.fn() +})) + +jest.mock('@salesforce/retail-react-app/app/hooks/use-geo-location', () => ({ + useGeolocation: jest.fn() +})) + +describe('StoreLocatorForm', () => { + const mockConfig = { + supportedCountries: [ + {countryCode: 'US', countryName: 'United States'}, + {countryCode: 'CA', countryName: 'Canada'} + ] + } + + const mockSetFormValues = jest.fn() + const mockSetDeviceCoordinates = jest.fn() + let user + + beforeEach(() => { + jest.clearAllMocks() + user = userEvent.setup() + + useStoreLocator.mockImplementation(() => ({ + config: mockConfig, + formValues: {countryCode: '', postalCode: ''}, + setFormValues: mockSetFormValues, + setDeviceCoordinates: mockSetDeviceCoordinates + })) + + useGeolocation.mockImplementation(() => ({ + coordinates: {latitude: null, longitude: null}, + error: null, + refresh: jest.fn() + })) + }) + + it('renders postal code input field', () => { + render() + const postalCodeInput = screen.queryByPlaceholderText('Enter postal code') + expect(postalCodeInput).not.toBeNull() + }) + + it('renders country selector when supportedCountries exist', () => { + render() + const countrySelect = screen.queryByText('Select a country') + expect(countrySelect).not.toBeNull() + }) + + it('renders "Use My Location" button', () => { + render() + const locationButton = screen.queryByText('Use My Location') + expect(locationButton).not.toBeNull() + }) + + it('submits form with entered values', async () => { + render() + + const countrySelect = screen.getByRole('combobox') + const postalCodeInput = screen.getByPlaceholderText('Enter postal code') + + await user.selectOptions(countrySelect, 'US') + await user.type(postalCodeInput, '12345') + + const findButton = screen.getByText('Find') + await user.click(findButton) + + expect(mockSetFormValues).toHaveBeenCalledWith({ + countryCode: 'US', + postalCode: '12345' + }) + }) + + it('shows validation error for empty postal code', async () => { + render() + + const findButton = screen.getByText('Find') + await user.click(findButton) + + const errorMessage = screen.queryByText('Please enter a postal code.') + expect(errorMessage).not.toBeNull() + }) + + it('clears form when "Use My Location" is clicked', async () => { + const mockRefresh = jest.fn() + useGeolocation.mockImplementation(() => ({ + coordinates: {latitude: null, longitude: null}, + error: null, + refresh: mockRefresh + })) + + render() + + const countrySelect = screen.getByRole('combobox') + const postalCodeInput = screen.getByPlaceholderText('Enter postal code') + + await user.selectOptions(countrySelect, 'US') + await user.type(postalCodeInput, '12345') + + const locationButton = screen.getByText('Use My Location') + await user.click(locationButton) + + expect(mockSetFormValues).toHaveBeenCalledWith({ + countryCode: '', + postalCode: '' + }) + expect(mockRefresh).toHaveBeenCalled() + }) + + it('updates device coordinates when geolocation is successful', () => { + const mockCoordinates = {latitude: 37.7749, longitude: -122.4194} + useGeolocation.mockImplementation(() => ({ + coordinates: mockCoordinates, + error: null, + refresh: jest.fn() + })) + + render() + + expect(mockSetDeviceCoordinates).toHaveBeenCalledWith(mockCoordinates) + }) + + it('shows geolocation error message when permission is denied', () => { + useGeolocation.mockImplementation(() => ({ + coordinates: {latitude: null, longitude: null}, + error: new Error('Geolocation permission denied'), + refresh: jest.fn() + })) + + render() + + const errorMessage = screen.queryByText('Please agree to share your location') + expect(errorMessage).not.toBeNull() + }) +}) diff --git a/packages/template-retail-react-app/app/components/store-locator/heading.jsx b/packages/template-retail-react-app/app/components/store-locator/heading.jsx new file mode 100644 index 0000000000..19e5184a1a --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/heading.jsx @@ -0,0 +1,19 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React from 'react' +import {Heading} from '@chakra-ui/react' + +export const StoreLocatorHeading = () => { + return ( + <> + + Find a Store + + + ) +} diff --git a/packages/template-retail-react-app/app/components/store-locator/heading.test.jsx b/packages/template-retail-react-app/app/components/store-locator/heading.test.jsx new file mode 100644 index 0000000000..15e769bda3 --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/heading.test.jsx @@ -0,0 +1,19 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React from 'react' +import {render, screen} from '@testing-library/react' +import {StoreLocatorHeading} from '@salesforce/retail-react-app/app/components/store-locator/heading' + +describe('StoreLocatorHeading', () => { + test('renders heading with correct text', () => { + render() + + const heading = screen.getByText('Find a Store') + expect(heading).toBeTruthy() + }) +}) diff --git a/packages/template-retail-react-app/app/components/store-locator/index.js b/packages/template-retail-react-app/app/components/store-locator/index.js new file mode 100644 index 0000000000..9ff04d62ff --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/index.js @@ -0,0 +1,9 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +export {StoreLocator} from './main' +export {StoreLocatorModal} from './modal' diff --git a/packages/template-retail-react-app/app/components/store-locator/list-item.jsx b/packages/template-retail-react-app/app/components/store-locator/list-item.jsx new file mode 100644 index 0000000000..489650447e --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/list-item.jsx @@ -0,0 +1,73 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React from 'react' +import PropTypes from 'prop-types' +import {AccordionItem, AccordionButton, AccordionIcon, AccordionPanel, Box} from '@chakra-ui/react' + +export const StoreLocatorListItem = ({store}) => { + return ( + + + {store.name && {store.name}} + + {store.address1} + + + {store.city}, {store.stateCode ? store.stateCode : ''} {store.postalCode} + + {store.distance !== undefined && ( + <> +
+ + {store.distance} {store.distanceUnit} + {' away'} + + + )} + {store.phone && ( + <> +
+ + {'Phone: '} + {store.phone} + + + )} + {store.storeHours && ( + <> + + View More + + + +
+ + + )} + + + ) +} + +StoreLocatorListItem.propTypes = { + store: PropTypes.shape({ + name: PropTypes.string, + address1: PropTypes.string.isRequired, + city: PropTypes.string.isRequired, + stateCode: PropTypes.string, + postalCode: PropTypes.string.isRequired, + distance: PropTypes.number, + distanceUnit: PropTypes.string, + phone: PropTypes.string, + storeHours: PropTypes.string + }).isRequired +} diff --git a/packages/template-retail-react-app/app/components/store-locator/list-item.test.jsx b/packages/template-retail-react-app/app/components/store-locator/list-item.test.jsx new file mode 100644 index 0000000000..95c2a71744 --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/list-item.test.jsx @@ -0,0 +1,58 @@ +/* + * Copyright (c) 2024, Salesforce, Inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ +import React from 'react' +import {screen} from '@testing-library/react' +import {Accordion} from '@chakra-ui/react' +import {renderWithProviders} from '@salesforce/retail-react-app/app/utils/test-utils' +import {StoreLocatorListItem} from '@salesforce/retail-react-app/app/components/store-locator/list-item' + +describe('StoreLocatorListItem', () => { + const mockStore = { + name: 'Test Store', + address1: '123 Test St', + city: 'San Francisco', + stateCode: 'CA', + postalCode: '94105', + phone: '555-1234', + distance: 0.5, + distanceUnit: 'mi', + storeHours: '

Mon-Fri: 9AM-9PM

' + } + + const renderWithAccordion = (component) => { + return renderWithProviders({component}) + } + + it('renders store information correctly', () => { + renderWithAccordion() + + expect(screen.getByText('Test Store')).toBeTruthy() + expect(screen.getByText('123 Test St')).toBeTruthy() + expect(screen.getByText(/San Francisco, CA 94105/)).toBeTruthy() + expect(screen.getByText('0.5 mi away')).toBeTruthy() + expect(screen.getByText('Phone: 555-1234')).toBeTruthy() + expect(screen.getByText('View More')).toBeTruthy() + }) + + it('handles missing optional fields', () => { + const storeWithMissingFields = { + name: 'Basic Store', + address1: '789 Basic St', + city: 'Simple City', + postalCode: '12345' + } + + renderWithAccordion() + + expect(screen.getByText('Basic Store')).toBeTruthy() + expect(screen.getByText('789 Basic St')).toBeTruthy() + expect(screen.getByText(/Simple City/)).toBeTruthy() + expect(screen.queryByText(/away/)).toBeNull() + expect(screen.queryByText(/Phone:/)).toBeNull() + expect(screen.queryByText('View More')).toBeNull() + }) +}) diff --git a/packages/template-retail-react-app/app/components/store-locator/list.jsx b/packages/template-retail-react-app/app/components/store-locator/list.jsx new file mode 100644 index 0000000000..432f3a665f --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/list.jsx @@ -0,0 +1,83 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React, {useEffect, useState} from 'react' +import {Accordion, AccordionItem, Box, Button} from '@chakra-ui/react' +import {StoreLocatorListItem} from '@salesforce/retail-react-app/app/components/store-locator/list-item' +import {useStoreLocator} from '@salesforce/retail-react-app/app/hooks/use-store-locator' + +export const StoreLocatorList = () => { + const {data, isLoading, config, formValues, mode} = useStoreLocator() + const [page, setPage] = useState(1) + useEffect(() => { + setPage(1) + }, [data]) + + const displayStoreLocatorStatusMessage = () => { + if (isLoading) return 'Loading locations...' + if (data?.total === 0) return 'Sorry, there are no locations in this area' + + if (mode === 'input') { + const countryName = + config.supportedCountries.length !== 0 + ? config.supportedCountries.find( + (o) => o.countryCode === formValues.countryCode + )?.countryName || config.defaultCountry + : config.defaultCountry + + return `Viewing stores within ${String(config.radius)}${String( + config.radiusUnit + )} of ${String(data?.data[0].postalCode)} in ${String(countryName)}` + } + + return 'Viewing stores near your location' + } + + const showNumberOfStores = page * config.defaultPageSize + const showLoadMoreButton = data?.total > showNumberOfStores + const storesToShow = data?.data?.slice(0, showNumberOfStores) || [] + + return ( + <> + + + + {displayStoreLocatorStatusMessage()} + + + {storesToShow?.map((store, index) => ( + + ))} + + {showLoadMoreButton && ( + + + + )} + + ) +} diff --git a/packages/template-retail-react-app/app/components/store-locator/list.test.jsx b/packages/template-retail-react-app/app/components/store-locator/list.test.jsx new file mode 100644 index 0000000000..b4fb00ea0f --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/list.test.jsx @@ -0,0 +1,141 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ +import React from 'react' +import {render, screen, fireEvent} from '@testing-library/react' +import {StoreLocatorList} from '@salesforce/retail-react-app/app/components/store-locator/list' +import {useStoreLocator} from '@salesforce/retail-react-app/app/hooks/use-store-locator' + +// Mock the useStoreLocator hook +jest.mock('@salesforce/retail-react-app/app/hooks/use-store-locator') + +// Mock store data +const mockStores = { + total: 3, + data: [ + { + name: 'Store 1', + address1: '123 Main St', + city: 'Boston', + stateCode: 'MA', + postalCode: '02108', + phone: '555-0123' + }, + { + name: 'Store 2', + address1: '456 Oak St', + city: 'Boston', + stateCode: 'MA', + postalCode: '02109', + phone: '555-0124' + }, + { + name: 'Store 3', + address1: '789 Pine St', + city: 'Boston', + stateCode: 'MA', + postalCode: '02110', + phone: '555-0125' + } + ] +} + +const defaultConfig = { + radius: 10, + radiusUnit: 'mi', + defaultPageSize: 2, + defaultCountry: 'United States', + supportedCountries: [{countryCode: 'US', countryName: 'United States'}] +} + +describe('StoreLocatorList', () => { + beforeEach(() => { + jest.clearAllMocks() + }) + + test('renders loading state', () => { + useStoreLocator.mockReturnValue({ + isLoading: true, + data: null, + config: defaultConfig, + formValues: {}, + mode: 'input' + }) + + render() + expect(screen.getByText('Loading locations...')).toBeTruthy() + }) + + test('renders no locations message', () => { + useStoreLocator.mockReturnValue({ + isLoading: false, + data: {total: 0, data: []}, + config: defaultConfig, + formValues: {}, + mode: 'input' + }) + + render() + expect(screen.getByText('Sorry, there are no locations in this area')).toBeTruthy() + }) + + test('renders stores with pagination', () => { + useStoreLocator.mockReturnValue({ + isLoading: false, + data: mockStores, + config: defaultConfig, + formValues: {countryCode: 'US'}, + mode: 'input' + }) + + render() + + // Initially shows only first 2 stores (defaultPageSize) + expect(screen.getByText('Store 1')).toBeTruthy() + expect(screen.getByText('Store 2')).toBeTruthy() + expect(screen.queryByText('Store 3')).toBeNull() + + // Load more button should be visible + const loadMoreButton = screen.getByText('Load More') + expect(loadMoreButton).toBeTruthy() + + // Click load more + fireEvent.click(loadMoreButton) + + // Should now show all 3 stores + expect(screen.getByText('Store 1')).toBeTruthy() + expect(screen.getByText('Store 2')).toBeTruthy() + expect(screen.getByText('Store 3')).toBeTruthy() + }) + + test('renders correct status message for input mode', () => { + useStoreLocator.mockReturnValue({ + isLoading: false, + data: mockStores, + config: defaultConfig, + formValues: {countryCode: 'US'}, + mode: 'input' + }) + + render() + expect( + screen.getByText(/Viewing stores within 10mi of 02108 in United States/) + ).toBeTruthy() + }) + + test('renders correct status message for geolocation mode', () => { + useStoreLocator.mockReturnValue({ + isLoading: false, + data: mockStores, + config: defaultConfig, + formValues: {}, + mode: 'geolocation' + }) + + render() + expect(screen.getByText('Viewing stores near your location')).toBeTruthy() + }) +}) diff --git a/packages/template-retail-react-app/app/components/store-locator/main.jsx b/packages/template-retail-react-app/app/components/store-locator/main.jsx new file mode 100644 index 0000000000..71750db949 --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/main.jsx @@ -0,0 +1,21 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React from 'react' +import {StoreLocatorList} from '@salesforce/retail-react-app/app/components/store-locator/list' +import {StoreLocatorForm} from '@salesforce/retail-react-app/app/components/store-locator/form' +import {StoreLocatorHeading} from '@salesforce/retail-react-app/app/components/store-locator/heading' + +export const StoreLocator = () => { + return ( + <> + + + + + ) +} diff --git a/packages/template-retail-react-app/app/components/store-locator/main.test.jsx b/packages/template-retail-react-app/app/components/store-locator/main.test.jsx new file mode 100644 index 0000000000..00d2e011ca --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/main.test.jsx @@ -0,0 +1,33 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React from 'react' +import {render, screen} from '@testing-library/react' +import {StoreLocator} from '@salesforce/retail-react-app/app/components/store-locator/main' + +jest.mock('./list', () => ({ + StoreLocatorList: () =>
Store List Mock
+})) + +jest.mock('./form', () => ({ + StoreLocatorForm: () =>
Store Form Mock
+})) + +jest.mock('./heading', () => ({ + StoreLocatorHeading: () =>
Store Heading Mock
+})) + +describe('StoreLocatorContent', () => { + it('renders all child components', () => { + render() + + // Verify that all child components are rendered + expect(screen.queryByTestId('store-locator-heading')).not.toBeNull() + expect(screen.queryByTestId('store-locator-form')).not.toBeNull() + expect(screen.queryByTestId('store-locator-list')).not.toBeNull() + }) +}) diff --git a/packages/template-retail-react-app/app/components/store-locator/modal.jsx b/packages/template-retail-react-app/app/components/store-locator/modal.jsx new file mode 100644 index 0000000000..eeb90b5d86 --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/modal.jsx @@ -0,0 +1,56 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React from 'react' +import PropTypes from 'prop-types' +import { + Modal, + ModalBody, + ModalCloseButton, + ModalContent, + useBreakpointValue +} from '@chakra-ui/react' +import {StoreLocator} from '@salesforce/retail-react-app/app/components/store-locator/main' + +export const StoreLocatorModal = ({isOpen, onClose}) => { + const isDesktopView = useBreakpointValue({base: false, lg: true}) + + return isDesktopView ? ( + + + + + + + + + ) : ( + + + + + + + + + ) +} + +StoreLocatorModal.propTypes = { + isOpen: PropTypes.bool.isRequired, + onClose: PropTypes.func.isRequired +} diff --git a/packages/template-retail-react-app/app/components/store-locator/modal.test.jsx b/packages/template-retail-react-app/app/components/store-locator/modal.test.jsx new file mode 100644 index 0000000000..ea33e91dc2 --- /dev/null +++ b/packages/template-retail-react-app/app/components/store-locator/modal.test.jsx @@ -0,0 +1,67 @@ +/* + * Copyright (c) 2024, Salesforce, Inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ +import React from 'react' +import {screen} from '@testing-library/react' +import {renderWithProviders} from '@salesforce/retail-react-app/app/utils/test-utils' +import {StoreLocatorModal} from '@salesforce/retail-react-app/app/components/store-locator/modal' + +const mockUseBreakpointValue = jest.fn() +jest.mock('@chakra-ui/react', () => { + const originalModule = jest.requireActual('@chakra-ui/react') + return { + ...originalModule, + useBreakpointValue: () => mockUseBreakpointValue + } +}) + +jest.mock('./main', () => ({ + StoreLocator: () =>
Store Locator Content
+})) + +describe('StoreLocatorModal', () => { + const mockProps = { + isOpen: true, + onClose: jest.fn() + } + + beforeEach(() => { + jest.clearAllMocks() + mockUseBreakpointValue.mockReturnValue(true) // Default to desktop view + }) + + it('renders desktop view correctly', () => { + mockUseBreakpointValue.mockReturnValue(true) // Desktop view + renderWithProviders() + + expect(screen.getByText('Store Locator Content')).toBeTruthy() + expect(screen.getByTestId('store-locator-content')).toBeTruthy() + }) + + it('renders mobile view correctly', () => { + mockUseBreakpointValue.mockReturnValue(false) // Mobile view + renderWithProviders() + + expect(screen.getByText('Store Locator Content')).toBeTruthy() + expect(screen.getByTestId('store-locator-content')).toBeTruthy() + }) + + it('does not render when closed', () => { + renderWithProviders() + + expect(screen.queryByText('Store Locator Content')).toBeNull() + expect(screen.queryByTestId('store-locator-content')).toBeNull() + }) + + it('calls onClose when close button is clicked', () => { + const onClose = jest.fn() + renderWithProviders() + + const closeButton = screen.getByLabelText('Close') + closeButton.click() + expect(onClose).toHaveBeenCalled() + }) +}) diff --git a/packages/template-retail-react-app/app/constants.js b/packages/template-retail-react-app/app/constants.js index ad8602e346..7db2216f5f 100644 --- a/packages/template-retail-react-app/app/constants.js +++ b/packages/template-retail-react-app/app/constants.js @@ -185,35 +185,24 @@ export const REMOVE_UNAVAILABLE_CART_ITEM_DIALOG_CONFIG = { onPrimaryAction: noop } -export const SUPPORTED_STORE_LOCATOR_COUNTRIES = [ +export const STORE_LOCATOR_IS_ENABLED = true +export const STORE_LOCATOR_SUPPORTED_COUNTRIES = [ { countryCode: 'US', - countryName: defineMessage({ - defaultMessage: 'United States', - id: 'store_locator.dropdown.united_states' - }) + countryName: 'United States' }, { countryCode: 'DE', - countryName: defineMessage({ - defaultMessage: 'Germany', - id: 'store_locator.dropdown.germany' - }) + countryName: 'Germany' } ] - -export const DEFAULT_STORE_LOCATOR_COUNTRY = { - countryCode: 'DE', - countryName: defineMessage({ - defaultMessage: 'Germany', - id: 'store_locator.dropdown.germany' - }) -} -export const DEFAULT_STORE_LOCATOR_POSTAL_CODE = '10178' -export const STORE_LOCATOR_DISTANCE = 100 -export const STORE_LOCATOR_NUM_STORES_PER_LOAD = 10 -export const STORE_LOCATOR_DISTANCE_UNIT = 'km' -export const STORE_LOCATOR_IS_ENABLED = true +export const STORE_LOCATOR_DEFAULT_POSTAL_CODE = '10178' +export const STORE_LOCATOR_RADIUS = 100 +export const STORE_LOCATOR_RADIUS_UNIT = 'km' +export const STORE_LOCATOR_DEFAULT_COUNTRY = 'DE' +export const STORE_LOCATOR_DEFAULT_COUNTRY_CODE = 'DE' +export const STORE_LOCATOR_DEFAULT_PAGE_SIZE = 10 +export const STORE_LOCATOR_NUM_STORES_PER_REQUEST_API_MAX = 200 // This is an API limit and is therefore not configurable export const DEFAULT_DNT_STATE = true // Constants for shopper context diff --git a/packages/template-retail-react-app/app/contexts/index.js b/packages/template-retail-react-app/app/contexts/index.js index 622a78b5e8..d542c27cfb 100644 --- a/packages/template-retail-react-app/app/contexts/index.js +++ b/packages/template-retail-react-app/app/contexts/index.js @@ -7,6 +7,10 @@ import React, {useState} from 'react' import PropTypes from 'prop-types' +export { + StoreLocatorContext, + StoreLocatorProvider +} from '@salesforce/retail-react-app/app/contexts/store-locator-provider' /** * This is the global state for the multiples sites and locales supported in the App. diff --git a/packages/template-retail-react-app/app/contexts/store-locator-provider.jsx b/packages/template-retail-react-app/app/contexts/store-locator-provider.jsx new file mode 100644 index 0000000000..51a8a88331 --- /dev/null +++ b/packages/template-retail-react-app/app/contexts/store-locator-provider.jsx @@ -0,0 +1,41 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import React, {useState, createContext} from 'react' +import PropTypes from 'prop-types' + +export const StoreLocatorContext = createContext(null) + +export const StoreLocatorProvider = ({config, children}) => { + const [state, setState] = useState({ + mode: 'input', + formValues: { + countryCode: config.defaultCountryCode, + postalCode: config.defaultPostalCode + }, + deviceCoordinates: { + latitude: null, + longitude: null + }, + config + }) + + const value = { + state, + setState + } + + return {children} +} + +StoreLocatorProvider.propTypes = { + config: PropTypes.shape({ + defaultCountryCode: PropTypes.string.isRequired, + defaultPostalCode: PropTypes.string.isRequired + }).isRequired, + children: PropTypes.node +} diff --git a/packages/template-retail-react-app/app/contexts/store-locator-provider.test.jsx b/packages/template-retail-react-app/app/contexts/store-locator-provider.test.jsx new file mode 100644 index 0000000000..43c0eca3af --- /dev/null +++ b/packages/template-retail-react-app/app/contexts/store-locator-provider.test.jsx @@ -0,0 +1,91 @@ +/* + * Copyright (c) 2024, Salesforce, Inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ +import React from 'react' +import {render, act} from '@testing-library/react' +import { + StoreLocatorProvider, + StoreLocatorContext +} from '@salesforce/retail-react-app/app/contexts/store-locator-provider' + +describe('StoreLocatorProvider', () => { + const mockConfig = { + defaultCountryCode: 'US', + defaultPostalCode: '10178' + } + + it('provides the expected context value', () => { + let contextValue + const TestComponent = () => { + contextValue = React.useContext(StoreLocatorContext) + return null + } + + render( + + + + ) + + expect(contextValue).toBeTruthy() + expect(contextValue?.state).toEqual({ + mode: 'input', + formValues: { + countryCode: mockConfig.defaultCountryCode, + postalCode: mockConfig.defaultPostalCode + }, + deviceCoordinates: { + latitude: null, + longitude: null + }, + config: mockConfig + }) + expect(typeof contextValue?.setState).toBe('function') + }) + + it('updates state correctly when setState is called', () => { + let contextValue + const TestComponent = () => { + contextValue = React.useContext(StoreLocatorContext) + return null + } + + render( + + + + ) + + act(() => { + contextValue?.setState((prev) => ({ + ...prev, + mode: 'device', + formValues: { + countryCode: 'US', + postalCode: '94105' + } + })) + }) + + expect(contextValue?.state.mode).toBe('device') + expect(contextValue?.state.formValues).toEqual({ + countryCode: 'US', + postalCode: '94105' + }) + }) + + it('renders children correctly', () => { + const TestChild = () =>
Test Child
+ + const {getByText} = render( + + + + ) + + expect(getByText('Test Child')).toBeTruthy() + }) +}) diff --git a/packages/template-retail-react-app/app/hooks/use-derived-product.test.js b/packages/template-retail-react-app/app/hooks/use-derived-product.test.js index 8feeddbd9a..012fd41db2 100644 --- a/packages/template-retail-react-app/app/hooks/use-derived-product.test.js +++ b/packages/template-retail-react-app/app/hooks/use-derived-product.test.js @@ -9,10 +9,15 @@ import React from 'react' import PropTypes from 'prop-types' import {screen} from '@testing-library/react' -import {createMemoryHistory} from 'history' import {useDerivedProduct} from '@salesforce/retail-react-app/app/hooks/use-derived-product' import mockProductDetail from '@salesforce/retail-react-app/app/mocks/variant-750518699578M' import {renderWithProviders} from '@salesforce/retail-react-app/app/utils/test-utils' +import {useVariant} from '@salesforce/retail-react-app/app/hooks/use-variant' + +// Mock the useVariant hook +jest.mock('@salesforce/retail-react-app/app/hooks/use-variant', () => ({ + useVariant: jest.fn() +})) const MockComponent = ({product}) => { const {inventoryMessage, quantity, variationParams, variant} = useDerivedProduct(product) @@ -32,9 +37,19 @@ MockComponent.propTypes = { } describe('useDerivedProduct hook', () => { - test('runs properly', () => { - const history = createMemoryHistory() - history.push('/test/path?test') + beforeEach(() => { + // Reset mock before each test + jest.clearAllMocks() + }) + + test('should not show out of stock message when stockLevel is greater then 0 and greater then asked quantity', () => { + // Mock useVariant to return a valid variant + useVariant.mockReturnValue({ + orderable: true, + price: 299.99, + productId: '750518699578M', + variationValues: {color: 'BLACKFB', size: '038', width: 'V'} + }) renderWithProviders() @@ -46,9 +61,14 @@ describe('useDerivedProduct hook', () => { ).toBeInTheDocument() }) - test('has out of stock message', () => { - const history = createMemoryHistory() - history.push('/test/path') + test('should show out of stock message when stockLevel is 0', () => { + // Mock useVariant to return a valid variant + useVariant.mockReturnValue({ + orderable: true, + price: 299.99, + productId: '750518699578M', + variationValues: {color: 'BLACKFB', size: '038', width: 'V'} + }) const mockData = { ...mockProductDetail, @@ -66,4 +86,81 @@ describe('useDerivedProduct hook', () => { expect(screen.getByText(/Out of stock/)).toBeInTheDocument() }) + + test('should show unfulfillable messsage when stockLevel is less then asked quantity', () => { + // Mock useVariant to return a valid variant + useVariant.mockReturnValue({ + orderable: true, + price: 299.99, + productId: '750518699578M', + variationValues: {color: 'BLACKFB', size: '038', width: 'V'} + }) + + const mockData = { + ...mockProductDetail, + quantity: 10, + inventory: { + ats: 0, + backorderable: false, + id: 'inventory_m', + orderable: false, + preorderable: false, + stockLevel: 5 + } + } + + renderWithProviders() + + expect(screen.getByText(/Only 5 left!/)).toBeInTheDocument() + }) + + test('should show of stock message for bundle products', () => { + // Mock useVariant to return null for bundle products (bundles don't have variants) + useVariant.mockReturnValue(null) + + const mockBundleData = { + ...mockProductDetail, + type: { + bundle: true + }, + inventory: { + ats: 10, + backorderable: false, + id: 'inventory_m', + orderable: true, + preorderable: false, + stockLevel: 10 + } + } + + renderWithProviders() + + // Bundle products should not show out of stock message when inventory is available + expect(screen.queryByText(/Out of stock/)).not.toBeInTheDocument() + }) + + test('should show unfulfillable message for bundle products', () => { + // Mock useVariant to return null for bundle products (bundles don't have variants) + useVariant.mockReturnValue(null) + + const mockBundleData = { + ...mockProductDetail, + type: { + bundle: true + }, + quantity: 15, + inventory: { + ats: 5, + backorderable: false, + id: 'inventory_m', + orderable: true, + preorderable: false, + stockLevel: 5 + } + } + + renderWithProviders() + + expect(screen.getByText(/Only 5 left!/)).toBeInTheDocument() + }) }) diff --git a/packages/template-retail-react-app/app/hooks/use-geo-location.js b/packages/template-retail-react-app/app/hooks/use-geo-location.js new file mode 100644 index 0000000000..5e6bab8e16 --- /dev/null +++ b/packages/template-retail-react-app/app/hooks/use-geo-location.js @@ -0,0 +1,56 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import {useEffect, useState} from 'react' + +export function useGeolocation(options = {}) { + const [loading, setLoading] = useState(true) + const [error, setError] = useState(null) + const [coordinates, setCoordinates] = useState({ + latitude: null, + longitude: null + }) + + const getLocation = () => { + setLoading(true) + setError(null) + + try { + if (!navigator.geolocation) { + throw new Error('Geolocation is not supported by this browser.') + } + navigator.geolocation.getCurrentPosition( + (position) => { + setCoordinates({ + latitude: position.coords.latitude, + longitude: position.coords.longitude + }) + setLoading(false) + }, + (err) => { + setError(err) + setLoading(false) + }, + options + ) + } catch (err) { + setError(err) + setLoading(false) + } + } + + useEffect(() => { + getLocation() + }, []) + + return { + coordinates, + loading, + error, + refresh: getLocation + } +} diff --git a/packages/template-retail-react-app/app/hooks/use-geo-location.test.js b/packages/template-retail-react-app/app/hooks/use-geo-location.test.js new file mode 100644 index 0000000000..8f122940a4 --- /dev/null +++ b/packages/template-retail-react-app/app/hooks/use-geo-location.test.js @@ -0,0 +1,162 @@ +/* + * Copyright (c) 2024, Salesforce, Inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ +import {renderHook, act} from '@testing-library/react' +import {useGeolocation} from '@salesforce/retail-react-app/app/hooks/use-geo-location' + +describe('useGeolocation', () => { + const mockGeolocation = { + getCurrentPosition: jest.fn() + } + + beforeEach(() => { + // Mock GeolocationPositionError if it's not defined + if (!global.GeolocationPositionError) { + global.GeolocationPositionError = function () { + this.code = 1 + this.message = '' + this.PERMISSION_DENIED = 1 + this.POSITION_UNAVAILABLE = 2 + this.TIMEOUT = 3 + } + } + + // Setup mock for navigator.geolocation + Object.defineProperty(global.navigator, 'geolocation', { + value: mockGeolocation, + writable: true + }) + }) + + afterEach(() => { + jest.clearAllMocks() + }) + + it('initializes with default values', () => { + const {result} = renderHook(() => useGeolocation()) + + expect(result.current).toEqual({ + coordinates: {latitude: null, longitude: null}, + loading: true, + error: null, + refresh: expect.any(Function) + }) + }) + + it('updates coordinates on successful geolocation', async () => { + const mockPosition = { + coords: { + latitude: 37.7749, + longitude: -122.4194, + accuracy: 0, + altitude: null, + altitudeAccuracy: null, + heading: null, + speed: null + }, + timestamp: Date.now() + } + + mockGeolocation.getCurrentPosition.mockImplementation((success) => { + success(mockPosition) + }) + + const {result} = renderHook(() => useGeolocation()) + + await act(async () => { + await new Promise((resolve) => setTimeout(resolve, 0)) + }) + + expect(result.current).toEqual({ + coordinates: { + latitude: 37.7749, + longitude: -122.4194 + }, + loading: false, + error: null, + refresh: expect.any(Function) + }) + }) + + it('handles geolocation errors', async () => { + const mockError = new global.GeolocationPositionError() + mockError.code = 1 + mockError.message = 'User denied geolocation' + + mockGeolocation.getCurrentPosition.mockImplementation((_success, error) => { + error(mockError) + }) + + const {result} = renderHook(() => useGeolocation()) + + await act(async () => { + await new Promise((resolve) => setTimeout(resolve, 0)) + }) + + expect(result.current).toEqual({ + coordinates: {latitude: null, longitude: null}, + loading: false, + error: mockError, + refresh: expect.any(Function) + }) + }) + + it('handles refresh function call', async () => { + const mockPosition = { + coords: { + latitude: 37.7749, + longitude: -122.4194, + accuracy: 0, + altitude: null, + altitudeAccuracy: null, + heading: null, + speed: null + }, + timestamp: Date.now() + } + + mockGeolocation.getCurrentPosition.mockImplementation((success) => { + success(mockPosition) + }) + + const {result} = renderHook(() => useGeolocation()) + + act(() => { + result.current.refresh() + }) + + await act(async () => { + await new Promise((resolve) => setTimeout(resolve, 0)) + }) + + expect(mockGeolocation.getCurrentPosition).toHaveBeenCalledTimes(2) + expect(result.current.coordinates).toEqual({ + latitude: 37.7749, + longitude: -122.4194 + }) + }) + + it('handles case when geolocation is not supported', async () => { + // First clear the mock + Object.defineProperty(global.navigator, 'geolocation', { + value: undefined, + writable: true + }) + + const {result} = renderHook(() => useGeolocation()) + + await act(async () => { + await new Promise((resolve) => setTimeout(resolve, 0)) + }) + + // Just check that we're in an error state with null coordinates + expect(result.current.loading).toBe(false) + expect(result.current.coordinates).toEqual({ + latitude: null, + longitude: null + }) + }) +}) diff --git a/packages/template-retail-react-app/app/hooks/use-store-locator.js b/packages/template-retail-react-app/app/hooks/use-store-locator.js new file mode 100644 index 0000000000..4c05057eec --- /dev/null +++ b/packages/template-retail-react-app/app/hooks/use-store-locator.js @@ -0,0 +1,85 @@ +/* + * Copyright (c) 2024, salesforce.com, inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ + +import {useContext} from 'react' +import {useSearchStores} from '@salesforce/commerce-sdk-react' +import {StoreLocatorContext} from '@salesforce/retail-react-app/app/contexts/store-locator-provider' + +const useStores = (state) => { + //This is an API limit and is therefore not configurable + const NUM_STORES_PER_REQUEST_API_MAX = 200 + const apiParameters = + state.mode === 'input' + ? { + countryCode: state.formValues.countryCode, + postalCode: state.formValues.postalCode, + maxDistance: state.config.radius, + limit: NUM_STORES_PER_REQUEST_API_MAX, + distanceUnit: state.config.radiusUnit + } + : { + latitude: state.deviceCoordinates.latitude, + longitude: state.deviceCoordinates.longitude, + maxDistance: state.config.radius, + limit: NUM_STORES_PER_REQUEST_API_MAX, + distanceUnit: state.config.radiusUnit + } + const shouldFetchStores = + Boolean( + state.mode === 'input' && state.formValues.countryCode && state.formValues.postalCode + ) || + Boolean( + state.mode === 'device' && + state.deviceCoordinates.latitude && + state.deviceCoordinates.longitude + ) + return useSearchStores( + { + parameters: apiParameters + }, + { + enabled: shouldFetchStores + } + ) +} + +export const useStoreLocator = () => { + const context = useContext(StoreLocatorContext) + if (!context) { + throw new Error('useStoreLocator must be used within a StoreLocatorProvider') + } + + const {state, setState} = context + const {data, isLoading} = useStores(state) + + // There are two modes, input and device. + // The input mode is when the user is searching for a store + // by entering a postal code and country code. + // The device mode is when the user is searching for a store by sharing their location. + // The mode is implicitly set by user's action. + const setFormValues = (formValues) => { + setState((prev) => ({...prev, formValues, mode: 'input'})) + } + + const setDeviceCoordinates = (coordinates) => { + setState((prev) => ({ + ...prev, + deviceCoordinates: coordinates, + mode: 'device', + formValues: {countryCode: '', postalCode: ''} + })) + } + + return { + ...state, + data, + isLoading, + // Actions + setFormValues, + setDeviceCoordinates + } +} diff --git a/packages/template-retail-react-app/app/hooks/use-store-locator.test.jsx b/packages/template-retail-react-app/app/hooks/use-store-locator.test.jsx new file mode 100644 index 0000000000..b899a49ba7 --- /dev/null +++ b/packages/template-retail-react-app/app/hooks/use-store-locator.test.jsx @@ -0,0 +1,190 @@ +/* + * Copyright (c) 2024, Salesforce, Inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ +import React from 'react' +import {renderHook, act} from '@testing-library/react' +import {useStoreLocator} from '@salesforce/retail-react-app/app/hooks/use-store-locator' +import {StoreLocatorProvider} from '@salesforce/retail-react-app/app/contexts/store-locator-provider' +import {useSearchStores} from '@salesforce/commerce-sdk-react' + +// Mock the commerce-sdk-react hook +jest.mock('@salesforce/commerce-sdk-react', () => ({ + useSearchStores: jest.fn() +})) + +const config = { + radius: 100, + radiusUnit: 'mi', + defaultCountryCode: 'US', + defaultPostalCode: '10178' +} + +const wrapper = ({children}) => { + return {children} +} + +describe('useStoreLocator', () => { + beforeEach(() => { + useSearchStores.mockReset() + // Default mock implementation + useSearchStores.mockReturnValue({ + data: undefined, + isLoading: false + }) + }) + + it('throws error when used outside provider', () => { + let error + try { + renderHook(() => useStoreLocator()) + } catch (err) { + error = err + } + + expect(error).toEqual(Error('useStoreLocator must be used within a StoreLocatorProvider')) + }) + + it('initializes with default values', () => { + const {result} = renderHook(() => useStoreLocator(), {wrapper}) + + expect(result.current).toMatchObject({ + mode: 'input', + formValues: { + countryCode: config.defaultCountryCode, + postalCode: config.defaultPostalCode + }, + deviceCoordinates: {latitude: null, longitude: null}, + isLoading: false, + data: undefined + }) + }) + + it('updates form values and switches to input mode', () => { + const {result} = renderHook(() => useStoreLocator(), {wrapper}) + + act(() => { + result.current.setFormValues({ + countryCode: 'US', + postalCode: '94105' + }) + }) + + expect(result.current.mode).toBe('input') + expect(result.current.formValues).toEqual({ + countryCode: 'US', + postalCode: '94105' + }) + }) + + it('updates device coordinates and switches to device mode', () => { + const {result} = renderHook(() => useStoreLocator(), {wrapper}) + + act(() => { + result.current.setDeviceCoordinates({ + latitude: 37.7749, + longitude: -122.4194 + }) + }) + + expect(result.current.mode).toBe('device') + expect(result.current.deviceCoordinates).toEqual({ + latitude: 37.7749, + longitude: -122.4194 + }) + // Should reset form values when switching to device mode + expect(result.current.formValues).toEqual({ + countryCode: '', + postalCode: '' + }) + }) + + it('calls useSearchStores with correct parameters in input mode', () => { + const {result} = renderHook(() => useStoreLocator(), {wrapper}) + + act(() => { + result.current.setFormValues({ + countryCode: 'US', + postalCode: '94105' + }) + }) + + expect(useSearchStores).toHaveBeenCalledWith( + { + parameters: { + countryCode: 'US', + postalCode: '94105', + maxDistance: 100, + limit: 200, + distanceUnit: 'mi' + } + }, + { + enabled: true + } + ) + }) + + it('calls useSearchStores with correct parameters in device mode', () => { + const {result} = renderHook(() => useStoreLocator(), {wrapper}) + + act(() => { + result.current.setDeviceCoordinates({ + latitude: 37.7749, + longitude: -122.4194 + }) + }) + + expect(useSearchStores).toHaveBeenCalledWith( + { + parameters: { + latitude: 37.7749, + longitude: -122.4194, + maxDistance: 100, + limit: 200, + distanceUnit: 'mi' + } + }, + { + enabled: true + } + ) + }) + + it('handles loading state', () => { + useSearchStores.mockReturnValue({ + data: undefined, + isLoading: true + }) + + const {result} = renderHook(() => useStoreLocator(), {wrapper}) + + expect(result.current.isLoading).toBe(true) + }) + + it('handles store data', () => { + const mockStoreData = [ + { + id: '1', + name: 'Test Store', + address: { + address1: '123 Test St', + city: 'Test City', + stateCode: 'CA', + postalCode: '94105' + } + } + ] + + useSearchStores.mockReturnValue({ + data: mockStoreData, + isLoading: false + }) + + const {result} = renderHook(() => useStoreLocator(), {wrapper}) + + expect(result.current.data).toEqual(mockStoreData) + }) +}) diff --git a/packages/template-retail-react-app/app/pages/account/orders.test.js b/packages/template-retail-react-app/app/pages/account/orders.test.js index de57b529a5..aefe93c80a 100644 --- a/packages/template-retail-react-app/app/pages/account/orders.test.js +++ b/packages/template-retail-react-app/app/pages/account/orders.test.js @@ -66,7 +66,7 @@ test('Renders order history and details', async () => { await screen.findAllByAltText( 'Pleated Bib Long Sleeve Shirt, Silver Grey, small', {}, - {timeout: 15000} + {timeout: 500} ) ).toHaveLength(3) @@ -93,3 +93,146 @@ test('Renders order history place holder when no orders', async () => { expect(await screen.findByTestId('account-order-history-place-holder')).toBeInTheDocument() }) + +describe('Order with empty product list', () => { + let user + beforeEach(async () => { + const emptyProductOrder = { + ...mockOrderHistory.data[0], + productItems: [] + } + const mockOrderHistoryWithEmptyProduct = { + ...mockOrderHistory, + data: [emptyProductOrder] + } + global.server.use( + rest.get('*/orders/:orderNo', (req, res, ctx) => { + return res(ctx.delay(0), ctx.json(emptyProductOrder)) + }), + rest.get('*/customers/:customerId/orders', (req, res, ctx) => { + return res(ctx.delay(0), ctx.json(mockOrderHistoryWithEmptyProduct)) + }) + ) + const renderResult = renderWithProviders(, { + wrapperProps: {siteAlias: 'uk', appConfig: mockConfig.app} + }) + user = renderResult.user + }) + + test('should render order history page', async () => { + expect(await screen.findByTestId('account-order-history-page')).toBeInTheDocument() + }) + + test('should render order details page', async () => { + await user.click((await screen.findAllByText(/view details/i))[0]) + expect(await screen.findByTestId('account-order-details-page')).toBeInTheDocument() + }) + + test('should show 0 items', async () => { + await user.click((await screen.findAllByText(/view details/i))[0]) + expect(await screen.findByText(/0 items/i)).toBeInTheDocument() + }) + + test('should not render products', async () => { + await user.click((await screen.findAllByText(/view details/i))[0]) + expect(screen.queryByAltText(/Pleated Bib Long Sleeve Shirt/i)).not.toBeInTheDocument() + }) +}) + +describe('Direct navigation to order details and back to order list', () => { + let user, orderNo + beforeEach(async () => { + global.server.use( + rest.get('*/orders/:orderNo', (req, res, ctx) => { + return res(ctx.delay(0), ctx.json(mockOrderHistory.data[0])) + }), + rest.get('*/customers/:customerId/orders', (req, res, ctx) => { + return res(ctx.delay(0), ctx.json(mockOrderHistory)) + }), + rest.get('*/products', (req, res, ctx) => { + return res(ctx.delay(0), ctx.json(mockOrderProducts)) + }) + ) + orderNo = mockOrderHistory.data[0].orderNo + window.history.pushState( + {}, + 'Order Details', + createPathWithDefaults(`/account/orders/${orderNo}`) + ) + const renderResult = renderWithProviders(, { + wrapperProps: {siteAlias: 'uk', appConfig: mockConfig.app} + }) + user = renderResult.user + }) + + test('should render order details page on direct navigation', async () => { + expect(await screen.findByTestId('account-order-details-page')).toBeInTheDocument() + expect(window.location.pathname).toMatch(new RegExp(`/account/orders/${orderNo}$`)) + }) + + test('should navigate back to order history page', async () => { + await user.click(await screen.findByRole('link', {name: /back to order history/i})) + expect(await screen.findByTestId('account-order-history-page')).toBeInTheDocument() + expect(window.location.pathname).toMatch(/\/account\/orders$/) + }) + + test('should show all orders', async () => { + await user.click(await screen.findByRole('link', {name: /back to order history/i})) + expect(await screen.findAllByText(/Ordered: /i)).toHaveLength(3) + }) + + test('should show all products', async () => { + await user.click(await screen.findByRole('link', {name: /back to order history/i})) + expect( + await screen.findAllByAltText( + 'Pleated Bib Long Sleeve Shirt, Silver Grey, small', + {}, + {timeout: 500} + ) + ).toHaveLength(3) + }) +}) + +describe('Handles order with missing or partial data gracefully', () => { + let orderNo + beforeEach(async () => { + const partialOrder = { + ...mockOrderHistory.data[0], + billingAddress: undefined, + shipments: undefined, + paymentInstruments: undefined, + creationDate: undefined + } + global.server.use( + rest.get('*/orders/:orderNo', (req, res, ctx) => { + return res(ctx.delay(0), ctx.json(partialOrder)) + }), + rest.get('*/customers/:customerId/orders', (req, res, ctx) => { + return res(ctx.delay(0), ctx.json({...mockOrderHistory, data: [partialOrder]})) + }) + ) + orderNo = partialOrder.orderNo + window.history.pushState( + {}, + 'Order Details', + createPathWithDefaults(`/account/orders/${orderNo}`) + ) + renderWithProviders(, { + wrapperProps: {siteAlias: 'uk', appConfig: mockConfig.app} + }) + }) + + test('should render order details page', async () => { + expect(await screen.findByTestId('account-order-details-page')).toBeInTheDocument() + }) + + test('should show the Order Details header', async () => { + expect(screen.getByRole('heading', {name: /order details/i})).toBeInTheDocument() + }) + + test('should not render billing, payment, or shipping sections', async () => { + expect(screen.queryByText(/billing address/i)).not.toBeInTheDocument() + expect(screen.queryByText(/payment method/i)).not.toBeInTheDocument() + expect(screen.queryByText(/shipping address/i)).not.toBeInTheDocument() + }) +}) diff --git a/packages/template-retail-react-app/app/pages/store-locator/index.jsx b/packages/template-retail-react-app/app/pages/store-locator/index.jsx index d568a5f807..16fbff6a77 100644 --- a/packages/template-retail-react-app/app/pages/store-locator/index.jsx +++ b/packages/template-retail-react-app/app/pages/store-locator/index.jsx @@ -1,49 +1,35 @@ /* - * Copyright (c) 2021, salesforce.com, inc. + * Copyright (c) 2024, salesforce.com, inc. * All rights reserved. * SPDX-License-Identifier: BSD-3-Clause * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause */ import React from 'react' +import {Box, Container} from '@chakra-ui/react' +import {StoreLocator} from '@salesforce/retail-react-app/app/components/store-locator' -// Components -import {Box, Container} from '@salesforce/retail-react-app/app/components/shared/ui' -import Seo from '@salesforce/retail-react-app/app/components/seo' -import StoreLocatorContent from '@salesforce/retail-react-app/app/components/store-locator-modal/store-locator-content' - -// Others -import { - StoreLocatorContext, - useStoreLocator -} from '@salesforce/retail-react-app/app/components/store-locator-modal/index' - -const StoreLocator = () => { - const storeLocator = useStoreLocator() - +const StoreLocatorPage = () => { return ( - - - - - - - - + + + + + ) } -StoreLocator.getTemplateName = () => 'store-locator' +StoreLocatorPage.getTemplateName = () => 'store-locator' -StoreLocator.propTypes = {} +StoreLocatorPage.propTypes = {} -export default StoreLocator +export default StoreLocatorPage diff --git a/packages/template-retail-react-app/app/pages/store-locator/index.test.jsx b/packages/template-retail-react-app/app/pages/store-locator/index.test.jsx index 959ad891cc..60f037b201 100644 --- a/packages/template-retail-react-app/app/pages/store-locator/index.test.jsx +++ b/packages/template-retail-react-app/app/pages/store-locator/index.test.jsx @@ -1,256 +1,36 @@ /* - * Copyright (c) 2021, salesforce.com, inc. + * Copyright (c) 2025, Salesforce, Inc. + * All rights reserved. + * SPDX-License-Identifier: BSD-3-Clause + * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause + */ +/* + * Copyright (c) 2024, salesforce.com, inc. * All rights reserved. * SPDX-License-Identifier: BSD-3-Clause * For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause */ -import React from 'react' -import {screen, waitFor, within} from '@testing-library/react' -import {rest} from 'msw' -import { - createPathWithDefaults, - renderWithProviders -} from '@salesforce/retail-react-app/app/utils/test-utils' -import StoreLocator from '.' -import mockConfig from '@salesforce/retail-react-app/config/mocks/default' - -const mockStores = { - limit: 4, - data: [ - { - address1: 'Kirchgasse 12', - city: 'Wiesbaden', - countryCode: 'DE', - distance: 0.74, - distanceUnit: 'km', - id: '00019', - inventoryId: 'inventory_m_store_store11', - latitude: 50.0826, - longitude: 8.24, - name: 'Wiesbaden Tech Depot', - phone: '+49 611 876543', - posEnabled: false, - postalCode: '65185', - storeHours: - 'Monday 9 AM–7 PM\nTuesday 9 AM–7 PM\nWednesday 9 AM–7 PM\nThursday 9 AM–8 PM\nFriday 9 AM–7 PM\nSaturday 9 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Schaumainkai 63', - city: 'Frankfurt am Main', - countryCode: 'DE', - distance: 30.78, - distanceUnit: 'km', - id: '00002', - inventoryId: 'inventory_m_store_store4', - latitude: 50.097416, - longitude: 8.669059, - name: 'Frankfurt Electronics Store', - phone: '+49 69 111111111', - posEnabled: false, - postalCode: '60596', - storeHours: - 'Monday 10 AM–6 PM\nTuesday 10 AM–6 PM\nWednesday 10 AM–6 PM\nThursday 10 AM–9 PM\nFriday 10 AM–6 PM\nSaturday 10 AM–6 PM\nSunday 10 AM–6 PM', - storeLocatorEnabled: true - }, - { - address1: 'Löhrstraße 87', - city: 'Koblenz', - countryCode: 'DE', - distance: 55.25, - distanceUnit: 'km', - id: '00035', - inventoryId: 'inventory_m_store_store27', - latitude: 50.3533, - longitude: 7.5946, - name: 'Koblenz Electronics Store', - phone: '+49 261 123456', - posEnabled: false, - postalCode: '56068', - storeHours: - 'Monday 9 AM–7 PM\nTuesday 9 AM–7 PM\nWednesday 9 AM–7 PM\nThursday 9 AM–8 PM\nFriday 9 AM–7 PM\nSaturday 9 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - }, - { - address1: 'Hauptstraße 47', - city: 'Heidelberg', - countryCode: 'DE', - distance: 81.1, - distanceUnit: 'km', - id: '00021', - inventoryId: 'inventory_m_store_store13', - latitude: 49.4077, - longitude: 8.6908, - name: 'Heidelberg Tech Mart', - phone: '+49 6221 123456', - posEnabled: false, - postalCode: '69117', - storeHours: - 'Monday 10 AM–7 PM\nTuesday 10 AM–7 PM\nWednesday 10 AM–7 PM\nThursday 10 AM–8 PM\nFriday 10 AM–7 PM\nSaturday 10 AM–6 PM\nSunday Closed', - storeLocatorEnabled: true - } - ], - offset: 0, - total: 4 -} - -const mockNoStores = { - limit: 4, - total: 0 -} - -const MockedComponent = () => { - return ( -
- -
- ) -} - -// Set up and clean up -beforeEach(() => { - jest.resetModules() - window.history.pushState({}, 'Store locator', createPathWithDefaults('/store-locator')) -}) -afterEach(() => { - jest.resetModules() - localStorage.clear() - jest.clearAllMocks() -}) - -test('Allows customer to go to store locator page', async () => { - global.server.use( - rest.get( - '*/shopper-stores/v1/organizations/v1/organizations/f_ecom_zzrf_001/store-search', - (req, res, ctx) => { - return res(ctx.delay(0), ctx.status(200), ctx.json(mockStores)) - } - ) - ) - - // render our test component - const {user} = renderWithProviders(, { - wrapperProps: {siteAlias: 'uk', appConfig: mockConfig.app} - }) - - await user.click(await screen.findByText('Find a Store')) - - await waitFor(() => { - expect(window.location.pathname).toBe('/uk/en-GB/store-locator') - }) -}) - -test('Allows customer to go to store locator page and then select a new store', async () => { - global.server.use( - rest.get( - 'https://www.domain.com/mobify/proxy/api/store/shopper-stores/v1/organizations/:organizationId/store-search', - (req, res, ctx) => { - return res(ctx.delay(0), ctx.status(200), ctx.json(mockStores)) - } - ) - ) - - const {user} = renderWithProviders(, { - wrapperProps: {siteAlias: 'uk', appConfig: mockConfig.app} - }) - - await user.click(await screen.findByText('Find a Store')) - - const countrySelect = await screen.findByDisplayValue('Select a country') - await user.selectOptions(countrySelect, 'DE') - - await user.type(screen.getByPlaceholderText(/Enter postal code/i), '69117') - - const findButtonInForm = screen.getByRole('button', {name: 'Find'}) - await user.click(findButtonInForm) - - const storeToSelect = 'Heidelberg Tech Mart' - await waitFor(() => { - expect(screen.getByText(storeToSelect)).toBeInTheDocument() - }) - - const storeNameElement = await screen.findByText(storeToSelect) - - const storeAccordionItem = storeNameElement.closest('.chakra-accordion__item') - if (!storeAccordionItem) { - throw new Error(`Could not find parent .chakra-accordion__item for store: ${storeToSelect}`) - } - - const storeRadio = within(storeAccordionItem).getByRole('radio') - - await user.click(storeRadio) - expect(storeRadio).toBeChecked() -}) - -test('Show no stores are found if there are no stores', async () => { - global.server.use( - rest.get( - '*/shopper-stores/v1/organizations/v1/organizations/f_ecom_zzrf_001/store-search', - (req, res, ctx) => { - return res(ctx.delay(0), ctx.status(200), ctx.json(mockNoStores)) - } - ) - ) - - // render our test component - renderWithProviders(, { - wrapperProps: {siteAlias: 'uk', appConfig: mockConfig.app} - }) - - await waitFor(() => { - const descriptionFindAStore = screen.getByText(/Find a Store/i) - const noLocationsInThisArea = screen.getByText( - /Sorry, there are no locations in this area/i - ) - expect(descriptionFindAStore).toBeInTheDocument() - expect(noLocationsInThisArea).toBeInTheDocument() - - expect(window.location.pathname).toBe('/uk/en-GB/store-locator') - }) -}) - -test('Allows customer to search for stores and expand to view store details', async () => { - global.server.use( - rest.get('*/shopper-stores/v1/organizations/*/store-search', (req, res, ctx) => { - return res(ctx.delay(0), ctx.status(200), ctx.json(mockStores)) - }) - ) - const {user} = renderWithProviders(, { - wrapperProps: {siteAlias: 'uk', appConfig: mockConfig.app} - }) - - await user.click(await screen.findByText('Find a Store')) - const countrySelect = await screen.findByDisplayValue('Select a country') - await user.selectOptions(countrySelect, 'DE') +import React from 'react' +import {render, screen} from '@testing-library/react' +import StoreLocatorPage from '@salesforce/retail-react-app/app/pages/store-locator/index' - const postalCodeInput = screen.getByPlaceholderText(/Enter postal code/i) - await user.type(postalCodeInput, '65185') +jest.mock('@salesforce/retail-react-app/app/components/store-locator', () => ({ + StoreLocator: () =>
Mock Content
+})) - const findButton = screen.getByRole('button', {name: 'Find'}) - await user.click(findButton) +describe('StoreLocatorPage', () => { + it('renders the store locator page with content', () => { + render() - await waitFor(() => { - expect(screen.getByText('Wiesbaden Tech Depot')).toBeInTheDocument() - expect(screen.getByText('Frankfurt Electronics Store')).toBeInTheDocument() - }) + // Verify the page wrapper is rendered + expect(screen.getByTestId('store-locator-page')).toBeTruthy() - await waitFor(() => { - expect(screen.getByText('Kirchgasse 12')).toBeInTheDocument() - expect(screen.getByText(/Phone:\s*\+49 611 876543/)).toBeInTheDocument() - expect(screen.getByText('0.74 km away')).toBeInTheDocument() + // Verify the mocked content is rendered + expect(screen.getByTestId('mock-store-locator-content')).toBeTruthy() }) - const wiesbadenStoreElement = await screen.findByText('Wiesbaden Tech Depot') - const wiesbadenAccordionItem = wiesbadenStoreElement.closest('.chakra-accordion__item') - - expect(wiesbadenAccordionItem).toBeTruthy() - - const viewMoreButton = within(wiesbadenAccordionItem).getByText('View More') - await user.click(viewMoreButton) - - await waitFor(() => { - expect(within(wiesbadenAccordionItem).getByText(/Monday 9 AM–7 PM/)).toBeInTheDocument() - expect(within(wiesbadenAccordionItem).getByText(/Sunday Closed/)).toBeInTheDocument() + it('returns correct template name', () => { + expect(StoreLocatorPage.getTemplateName()).toBe('store-locator') }) }) diff --git a/packages/template-retail-react-app/app/static/translations/compiled/de-DE.json b/packages/template-retail-react-app/app/static/translations/compiled/de-DE.json index 0142e85b09..33e82038aa 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/de-DE.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/de-DE.json @@ -437,6 +437,16 @@ "value": "Artikel aus dem Warenkorb entfernt" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 0, + "value": "Modales Bearbeitungsfenster für " + }, + { + "type": 1, + "value": "productName" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -539,6 +549,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "Kategorien" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -653,6 +669,24 @@ "value": "Versand" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "Ursprünglich " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": ", jetzt " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -819,6 +853,12 @@ "value": "Kreditkarte" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "Formular für Rechnungsadresse" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -861,6 +901,18 @@ "value": "Ja" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "Nein, Aktion abbrechen" + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "Ja, Aktion bestätigen" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -891,6 +943,24 @@ "value": "Ja, Artikel entfernen" } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "Nein, Artikel beibehalten" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "Nicht verfügbare Produkte entfernen" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "Ja, Artikel entfernen" + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, @@ -999,6 +1069,56 @@ "value": "Informationen zum Sicherheitscode" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "aktueller Preis " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "Ab aktuellem Preis " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "ursprünglicher Preis " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "Ab ursprünglichem Preis " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 0, + "value": "Von " + }, + { + "type": 1, + "value": "currentPrice" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1029,6 +1149,12 @@ "value": "Bestellverlauf" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "Menü-Drawer" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1417,6 +1543,12 @@ "value": "Menü" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "Öffnet einen Dialog" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1439,6 +1571,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "Shop-Finder" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1649,6 +1787,12 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "Ausgewählte Optionen" + } + ], "item_image.label.sale": [ { "type": 0, @@ -1661,10 +1805,32 @@ "value": "Nicht verfügbar" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ + { + "type": 0, + "value": "Menge " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 0, + "value": "Mengenauswahl für " + }, + { + "type": 1, + "value": "productName" + }, { "type": 0, - "value": "Ab" + "value": ". Die gewählte Menge ist " + }, + { + "type": 1, + "value": "quantity" } ], "lCPCxk": [ @@ -2477,14 +2643,28 @@ "value": " aus der Wunschliste entfernt" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { "type": 0, - "value": "Ab " - }, + "value": "Neu" + } + ], + "product_tile.badge.label.sale": [ { - "type": 1, - "value": "price" + "type": 0, + "value": "Sonderangebot" + } + ], + "product_view.button.add_bundle_to_cart": [ + { + "type": 0, + "value": "Bündel in den Warenkorb legen" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "Bündel zur Wunschliste hinzufügen" } ], "product_view.button.add_set_to_cart": [ @@ -2520,13 +2700,21 @@ "product_view.label.assistive_msg.quantity_decrement": [ { "type": 0, - "value": "Menge verringern" + "value": "Menge verringern für " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.assistive_msg.quantity_increment": [ { "type": 0, - "value": "Menge erhöhen" + "value": "Menge erhöhen für " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.quantity": [ @@ -2547,12 +2735,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "Ab" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2664,7 +2846,7 @@ "children": [ { "type": 0, - "value": "Datenschutzerklärung" + "value": "Datenschutzrichtlinie" } ], "type": 8, @@ -2678,7 +2860,7 @@ "children": [ { "type": 0, - "value": "allgemeinen Geschäftsbedingungen" + "value": "Allgemeinen Geschäftsbedingungen" } ], "type": 8, @@ -2787,6 +2969,32 @@ "value": "Weiter zur Versandmethode" } ], + "shipping_address.label.edit_button": [ + { + "type": 1, + "value": "address" + }, + { + "type": 0, + "value": " bearbeiten" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 1, + "value": "address" + }, + { + "type": 0, + "value": " entfernen" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "Formular für die Lieferadresse" + } + ], "shipping_address.title.shipping_address": [ { "type": 0, @@ -2877,6 +3085,144 @@ "value": "Möchten Sie sich wirklich abmelden? Sie müssen sich wieder anmelden, um mit Ihrer aktuellen Bestellung fortzufahren." } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "Suchen" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "Land auswählen" + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "Meinen Standort verwenden" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "Mehr anzeigen" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "entfernt" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "Standorte werden geladen …" + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "Leider gibt es in dieser Gegend keine Standorte." + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "Oder" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "Telefon:" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 0, + "value": "Anzeige von Geschäften innerhalb von " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 0, + "value": " " + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " von " + }, + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": " in" + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "Anzeige von Geschäften in der Nähe Ihres Standorts" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "Deutschland" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "USA" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "Bitte stimmen Sie zu, Ihren Standort zu teilen." + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "Bitte geben Sie eine Postleitzahl ein." + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "Bitte wählen Sie ein Land aus." + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "Postleitzahl eingeben" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "Mehr laden" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "Ein Geschäft finden" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2893,6 +3239,30 @@ "value": "Bearbeiten" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "Kontaktinformationen bearbeiten" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "Zahlungsinformationen bearbeiten" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "Lieferadresse bearbeiten" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "Versandoptionen bearbeiten" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -3153,12 +3523,44 @@ "value": " vorhanden!" } ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 0, + "value": "Nur noch " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": " von " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " vorhanden!" + } + ], "use_product.message.out_of_stock": [ { "type": 0, "value": "Nicht vorrätig" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 0, + "value": "Nicht vorrätig für " + }, + { + "type": 1, + "value": "productName" + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3387,6 +3789,26 @@ "value": "Neues Passwort" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "-Set im Warenkorb ablegen" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " im Warenkorb ablegen" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3399,6 +3821,16 @@ "value": "In den Warenkorb" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 0, + "value": "Vollständige Details anzeigen für " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3411,6 +3843,16 @@ "value": "Optionen anzeigen" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 0, + "value": "Optionen anzeigen für " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3455,6 +3897,16 @@ "value": "Entfernen" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " entfernen" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/en-GB.json b/packages/template-retail-react-app/app/static/translations/compiled/en-GB.json index 352d183530..51fe13a1ae 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/en-GB.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/en-GB.json @@ -1901,12 +1901,6 @@ "value": "Secure" } ], - "item_attributes.label.is_bonus_product": [ - { - "type": 0, - "value": "Bonus Product" - } - ], "item_attributes.label.promotions": [ { "type": 0, @@ -3289,140 +3283,6 @@ "value": " to proceed." } ], - "store_locator.action.find": [ - { - "type": 0, - "value": "Find" - } - ], - "store_locator.action.select_a_country": [ - { - "type": 0, - "value": "Select a country" - } - ], - "store_locator.action.use_my_location": [ - { - "type": 0, - "value": "Use My Location" - } - ], - "store_locator.action.viewMore": [ - { - "type": 0, - "value": "View More" - } - ], - "store_locator.description.away": [ - { - "type": 0, - "value": "away" - } - ], - "store_locator.description.loading_locations": [ - { - "type": 0, - "value": "Loading locations..." - } - ], - "store_locator.description.no_locations": [ - { - "type": 0, - "value": "Sorry, there are no locations in this area" - } - ], - "store_locator.description.or": [ - { - "type": 0, - "value": "Or" - } - ], - "store_locator.description.phone": [ - { - "type": 0, - "value": "Phone:" - } - ], - "store_locator.description.viewing_near_postal_code": [ - { - "type": 0, - "value": "Viewing stores within " - }, - { - "type": 1, - "value": "distance" - }, - { - "type": 1, - "value": "distanceUnit" - }, - { - "type": 0, - "value": " of " - }, - { - "type": 1, - "value": "postalCode" - }, - { - "type": 0, - "value": " in" - } - ], - "store_locator.description.viewing_near_your_location": [ - { - "type": 0, - "value": "Viewing stores near your location" - } - ], - "store_locator.dropdown.germany": [ - { - "type": 0, - "value": "Germany" - } - ], - "store_locator.dropdown.united_states": [ - { - "type": 0, - "value": "United States" - } - ], - "store_locator.error.agree_to_share_your_location": [ - { - "type": 0, - "value": "Please agree to share your location" - } - ], - "store_locator.error.please_enter_a_postal_code": [ - { - "type": 0, - "value": "Please enter a postal code." - } - ], - "store_locator.error.please_select_a_country": [ - { - "type": 0, - "value": "Please select a country." - } - ], - "store_locator.field.placeholder.enter_postal_code": [ - { - "type": 0, - "value": "Enter postal code" - } - ], - "store_locator.pagination.load_more": [ - { - "type": 0, - "value": "Load More" - } - ], - "store_locator.title": [ - { - "type": 0, - "value": "Find a Store" - } - ], "swatch_group.selected.label": [ { "type": 1, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/en-US.json b/packages/template-retail-react-app/app/static/translations/compiled/en-US.json index 352d183530..51fe13a1ae 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/en-US.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/en-US.json @@ -1901,12 +1901,6 @@ "value": "Secure" } ], - "item_attributes.label.is_bonus_product": [ - { - "type": 0, - "value": "Bonus Product" - } - ], "item_attributes.label.promotions": [ { "type": 0, @@ -3289,140 +3283,6 @@ "value": " to proceed." } ], - "store_locator.action.find": [ - { - "type": 0, - "value": "Find" - } - ], - "store_locator.action.select_a_country": [ - { - "type": 0, - "value": "Select a country" - } - ], - "store_locator.action.use_my_location": [ - { - "type": 0, - "value": "Use My Location" - } - ], - "store_locator.action.viewMore": [ - { - "type": 0, - "value": "View More" - } - ], - "store_locator.description.away": [ - { - "type": 0, - "value": "away" - } - ], - "store_locator.description.loading_locations": [ - { - "type": 0, - "value": "Loading locations..." - } - ], - "store_locator.description.no_locations": [ - { - "type": 0, - "value": "Sorry, there are no locations in this area" - } - ], - "store_locator.description.or": [ - { - "type": 0, - "value": "Or" - } - ], - "store_locator.description.phone": [ - { - "type": 0, - "value": "Phone:" - } - ], - "store_locator.description.viewing_near_postal_code": [ - { - "type": 0, - "value": "Viewing stores within " - }, - { - "type": 1, - "value": "distance" - }, - { - "type": 1, - "value": "distanceUnit" - }, - { - "type": 0, - "value": " of " - }, - { - "type": 1, - "value": "postalCode" - }, - { - "type": 0, - "value": " in" - } - ], - "store_locator.description.viewing_near_your_location": [ - { - "type": 0, - "value": "Viewing stores near your location" - } - ], - "store_locator.dropdown.germany": [ - { - "type": 0, - "value": "Germany" - } - ], - "store_locator.dropdown.united_states": [ - { - "type": 0, - "value": "United States" - } - ], - "store_locator.error.agree_to_share_your_location": [ - { - "type": 0, - "value": "Please agree to share your location" - } - ], - "store_locator.error.please_enter_a_postal_code": [ - { - "type": 0, - "value": "Please enter a postal code." - } - ], - "store_locator.error.please_select_a_country": [ - { - "type": 0, - "value": "Please select a country." - } - ], - "store_locator.field.placeholder.enter_postal_code": [ - { - "type": 0, - "value": "Enter postal code" - } - ], - "store_locator.pagination.load_more": [ - { - "type": 0, - "value": "Load More" - } - ], - "store_locator.title": [ - { - "type": 0, - "value": "Find a Store" - } - ], "swatch_group.selected.label": [ { "type": 1, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/en-XA.json b/packages/template-retail-react-app/app/static/translations/compiled/en-XA.json index 75acacecc2..bc4d6a72bb 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/en-XA.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/en-XA.json @@ -4013,20 +4013,6 @@ "value": "]" } ], - "item_attributes.label.is_bonus_product": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ɓǿǿƞŭŭş Ƥřǿǿḓŭŭƈŧ" - }, - { - "type": 0, - "value": "]" - } - ], "item_attributes.label.promotions": [ { "type": 0, @@ -7001,292 +6987,6 @@ "value": "]" } ], - "store_locator.action.find": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ƒīƞḓ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.action.select_a_country": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Şḗḗŀḗḗƈŧ ȧȧ ƈǿǿŭŭƞŧřẏ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.action.use_my_location": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ŭşḗḗ Ḿẏ Ŀǿǿƈȧȧŧīǿǿƞ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.action.viewMore": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ṽīḗḗẇ Ḿǿǿřḗḗ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.description.away": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "ȧȧẇȧȧẏ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.description.loading_locations": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ŀǿǿȧȧḓīƞɠ ŀǿǿƈȧȧŧīǿǿƞş..." - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.description.no_locations": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Şǿǿřřẏ, ŧħḗḗřḗḗ ȧȧřḗḗ ƞǿǿ ŀǿǿƈȧȧŧīǿǿƞş īƞ ŧħīş ȧȧřḗḗȧȧ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.description.or": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ǿř" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.description.phone": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ƥħǿǿƞḗḗ:" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.description.viewing_near_postal_code": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ṽīḗḗẇīƞɠ şŧǿǿřḗḗş ẇīŧħīƞ " - }, - { - "type": 1, - "value": "distance" - }, - { - "type": 1, - "value": "distanceUnit" - }, - { - "type": 0, - "value": " ǿǿƒ " - }, - { - "type": 1, - "value": "postalCode" - }, - { - "type": 0, - "value": " īƞ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.description.viewing_near_your_location": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ṽīḗḗẇīƞɠ şŧǿǿřḗḗş ƞḗḗȧȧř ẏǿǿŭŭř ŀǿǿƈȧȧŧīǿǿƞ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.dropdown.germany": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ɠḗḗřḿȧȧƞẏ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.dropdown.united_states": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ŭƞīŧḗḗḓ Şŧȧȧŧḗḗş" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.error.agree_to_share_your_location": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ƥŀḗḗȧȧşḗḗ ȧȧɠřḗḗḗḗ ŧǿǿ şħȧȧřḗḗ ẏǿǿŭŭř ŀǿǿƈȧȧŧīǿǿƞ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.error.please_enter_a_postal_code": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ƥŀḗḗȧȧşḗḗ ḗḗƞŧḗḗř ȧȧ ƥǿǿşŧȧȧŀ ƈǿǿḓḗḗ." - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.error.please_select_a_country": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ƥŀḗḗȧȧşḗḗ şḗḗŀḗḗƈŧ ȧȧ ƈǿǿŭŭƞŧřẏ." - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.field.placeholder.enter_postal_code": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ḗƞŧḗḗř ƥǿǿşŧȧȧŀ ƈǿǿḓḗḗ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.pagination.load_more": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ŀǿǿȧȧḓ Ḿǿǿřḗḗ" - }, - { - "type": 0, - "value": "]" - } - ], - "store_locator.title": [ - { - "type": 0, - "value": "[" - }, - { - "type": 0, - "value": "Ƒīƞḓ ȧȧ Şŧǿǿřḗḗ" - }, - { - "type": 0, - "value": "]" - } - ], "swatch_group.selected.label": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/es-MX.json b/packages/template-retail-react-app/app/static/translations/compiled/es-MX.json index 53ef078c5d..8f0a5b311c 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/es-MX.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/es-MX.json @@ -437,6 +437,16 @@ "value": "Artículo eliminado del carrito" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 0, + "value": "Editar modal para " + }, + { + "type": 1, + "value": "productName" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -539,6 +549,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "Categorías" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -653,6 +669,24 @@ "value": "Envío" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "Originalmente " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": ", ahora " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -819,6 +853,12 @@ "value": "Tarjeta de crédito" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "Formulario de dirección de facturación" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -861,6 +901,18 @@ "value": "Sí" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "No, cancelar acción" + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "Sí, confirme la acción" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -891,6 +943,24 @@ "value": "Sí, eliminar artículo" } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "No, conservar artículo" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "Eliminar productos no disponibles" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "Sí, eliminar artículo" + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, @@ -999,6 +1069,56 @@ "value": "Información del código de seguridad" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "precio actual " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "A partir del precio actual " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "precio original " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "Desde el precio original " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 0, + "value": "De " + }, + { + "type": 1, + "value": "currentPrice" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1029,6 +1149,12 @@ "value": "Historial de pedidos" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "Cajón de menú" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1080,7 +1206,7 @@ "drawer_menu.link.sign_in": [ { "type": 0, - "value": "Registrarte" + "value": "Registrarse" } ], "drawer_menu.link.site_map": [ @@ -1417,6 +1543,12 @@ "value": "Menú" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "Abre un cuadro de diálogo" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1439,6 +1571,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "Localizador de tiendas" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1649,6 +1787,12 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "Opciones seleccionadas:" + } + ], "item_image.label.sale": [ { "type": 0, @@ -1661,10 +1805,32 @@ "value": "No disponible" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ { "type": 0, - "value": "Comienza en" + "value": "Cantidad " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 0, + "value": "Selector de cantidad para " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": ". La cantidad seleccionada es " + }, + { + "type": 1, + "value": "quantity" } ], "lCPCxk": [ @@ -2489,14 +2655,28 @@ "value": " de la lista de deseos" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { "type": 0, - "value": "Comienza en " - }, + "value": "Crear" + } + ], + "product_tile.badge.label.sale": [ { - "type": 1, - "value": "price" + "type": 0, + "value": "Ofertas" + } + ], + "product_view.button.add_bundle_to_cart": [ + { + "type": 0, + "value": "Agregar paquete al carrito" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "Añadir paquete a la lista de deseos" } ], "product_view.button.add_set_to_cart": [ @@ -2532,13 +2712,21 @@ "product_view.label.assistive_msg.quantity_decrement": [ { "type": 0, - "value": "Cantidad de decremento" + "value": "Disminuir la cantidad de " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.assistive_msg.quantity_increment": [ { "type": 0, - "value": "Incrementar cantidad" + "value": "Incrementar cantidad de " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.quantity": [ @@ -2559,12 +2747,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "Comienza en" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2799,6 +2981,32 @@ "value": "Continuar a método de envío" } ], + "shipping_address.label.edit_button": [ + { + "type": 0, + "value": "Editar " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 0, + "value": "Eliminar " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "Formulario de dirección de envío" + } + ], "shipping_address.title.shipping_address": [ { "type": 0, @@ -2889,6 +3097,140 @@ "value": "¿Está seguro de que desea cerrar sesión? Deberá volver a registrarse para continuar con su pedido actual." } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "Encontrar" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "Seleccionar un país..." + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "Usar mi ubicación" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "Ver más" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "de distancia" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "Lugares de carga..." + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "Lo sentimos, no hay ubicaciones en esta área" + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "O" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "Teléfono:" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 0, + "value": "Visualización de tiendas dentro " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " de " + }, + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": " en" + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "Ver tiendas cerca de tu ubicación" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "Alemania" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "Estados Unidos" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "Acepte compartir su ubicación" + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "Introduzca un código postal." + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "Seleccione un país." + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "Ingrese el código postal" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "Cargar más" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "Buscar una tienda" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2905,6 +3247,30 @@ "value": "Editar" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "Editar información de contacto" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "Editar información de pago" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "Editar dirección de envío" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "Editar opciones de envío" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -2956,7 +3322,7 @@ "use_address_fields.error.please_select_your_state_or_province": [ { "type": 0, - "value": "Seleccione su estado/provincia." + "value": "Seleccione su estado." } ], "use_address_fields.error.required": [ @@ -3165,12 +3531,44 @@ "value": "!" } ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 0, + "value": "¡Solo " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": " queda para " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "!" + } + ], "use_product.message.out_of_stock": [ { "type": 0, "value": "Agotado" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 0, + "value": "Agotado para " + }, + { + "type": 1, + "value": "productName" + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3399,6 +3797,34 @@ "value": "Contraseña nueva" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 0, + "value": "Agregar conjunto de " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " al carrito" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 0, + "value": "Agregar " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " al carrito" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3411,6 +3837,16 @@ "value": "Agregar al carrito" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 0, + "value": "Ver todos los detalles de " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3423,6 +3859,16 @@ "value": "Ver opciones" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 0, + "value": "Ver opciones para " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3467,6 +3913,16 @@ "value": "Eliminar" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 0, + "value": "Eliminar " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/fr-FR.json b/packages/template-retail-react-app/app/static/translations/compiled/fr-FR.json index 45ec55f871..ad655d64aa 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/fr-FR.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/fr-FR.json @@ -437,6 +437,16 @@ "value": "Article supprimé du panier" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 0, + "value": "Modifier la fenêtre modale pour " + }, + { + "type": 1, + "value": "productName" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -539,6 +549,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "Catégories" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -653,6 +669,24 @@ "value": "Livraison" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "À l’origine " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": ", aujourd’hui " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -819,6 +853,12 @@ "value": "Carte de crédit" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "Formulaire d’adresse de facturation" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -861,6 +901,18 @@ "value": "Oui" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "Non, annuler l’action" + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "Oui, confirmer l’action" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -891,6 +943,24 @@ "value": "Oui, supprimer l’article" } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "Non, garder l’article" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "Supprimer les produits non disponibles" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "Oui, supprimer l’article" + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, @@ -999,6 +1069,56 @@ "value": "Cryptogramme" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "prix actuel " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "À partir du prix actuel " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "prix d’origine " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "À partir du prix d’origine " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 0, + "value": "Du " + }, + { + "type": 1, + "value": "currentPrice" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1029,6 +1149,12 @@ "value": "Historique des commandes" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "Tiroir de menu" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1417,6 +1543,12 @@ "value": "Menu" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "Ouvre une boîte de dialogue" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1439,6 +1571,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "Localisateur de magasins" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1649,10 +1787,16 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "Options sélectionnées" + } + ], "item_image.label.sale": [ { "type": 0, - "value": "Vente" + "value": "En solde" } ], "item_image.label.unavailable": [ @@ -1661,10 +1805,32 @@ "value": "Non disponible" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ { "type": 0, - "value": "À partir de" + "value": "Quantité " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 0, + "value": "Sélecteur de quantité pour " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": ". La quantité sélectionnée est " + }, + { + "type": 1, + "value": "quantity" } ], "lCPCxk": [ @@ -2489,14 +2655,28 @@ "value": " de la liste de souhaits" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { "type": 0, - "value": "À partir de " - }, + "value": "Nouveau" + } + ], + "product_tile.badge.label.sale": [ { - "type": 1, - "value": "price" + "type": 0, + "value": "En solde" + } + ], + "product_view.button.add_bundle_to_cart": [ + { + "type": 0, + "value": "Ajouter l’offre groupée au panier" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "Ajouter l’offre groupée à la liste de souhaits" } ], "product_view.button.add_set_to_cart": [ @@ -2532,13 +2712,21 @@ "product_view.label.assistive_msg.quantity_decrement": [ { "type": 0, - "value": "Décrémenter la quantité" + "value": "Décrémenter la quantité pour " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.assistive_msg.quantity_increment": [ { "type": 0, - "value": "Incrémenter la quantité" + "value": "Incrémenter la quantité pour " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.quantity": [ @@ -2559,12 +2747,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "À partir de" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2799,6 +2981,32 @@ "value": "Continuer vers le mode de livraison" } ], + "shipping_address.label.edit_button": [ + { + "type": 0, + "value": "Modifier " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 0, + "value": "Supprimer " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "Formulaire d’adresse de livraison" + } + ], "shipping_address.title.shipping_address": [ { "type": 0, @@ -2889,6 +3097,144 @@ "value": "Voulez-vous vraiment vous déconnecter ? Vous devrez vous reconnecter pour poursuivre votre commande en cours." } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "Rechercher" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "Sélectionner un pays" + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "Utiliser mon emplacement" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "Afficher plus" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "à" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "Lieux de chargement..." + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "Désolé, il n’y a pas d’emplacements dans cette zone" + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "Ou" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "Téléphone :" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 0, + "value": "Affichage des magasins à moins de " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 0, + "value": " " + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " de " + }, + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": " dans ce pays :" + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "Affichage des magasins à proximité de votre emplacement" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "Allemagne" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "États-Unis" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "Veuillez accepter de partager votre emplacement" + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "Veuillez saisir un code postal." + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "Veuillez sélectionner un pays." + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "Entrer un code postal" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "Charger plus de résultats" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "Trouver un magasin" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2905,6 +3251,30 @@ "value": "Modifier" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "Modifier les coordonnées" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "Modifier les informations de paiement" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "Modifier l’adresse de livraison" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "Modifier les options de livraison" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -3165,12 +3535,44 @@ "value": " !" } ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 0, + "value": "Il ne reste plus que " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": " articles pour " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " !" + } + ], "use_product.message.out_of_stock": [ { "type": 0, "value": "En rupture de stock" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 0, + "value": "Rupture de stock pour " + }, + { + "type": 1, + "value": "productName" + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3399,6 +3801,34 @@ "value": "Nouveau mot de passe" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 0, + "value": "Ajouter le lot " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " au panier" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 0, + "value": "Ajouter le " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " au panier" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3411,6 +3841,16 @@ "value": "Ajouter au panier" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 0, + "value": "Afficher tous les détails pour " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3423,6 +3863,16 @@ "value": "Afficher les options" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 0, + "value": "Afficher les options pour " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3467,6 +3917,16 @@ "value": "Supprimer" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 0, + "value": "Supprimer " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/it-IT.json b/packages/template-retail-react-app/app/static/translations/compiled/it-IT.json index 73033848dd..d215e143ae 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/it-IT.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/it-IT.json @@ -437,6 +437,16 @@ "value": "Articolo rimosso dal carrello" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 0, + "value": "Modifica modale per " + }, + { + "type": 1, + "value": "productName" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -539,6 +549,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "Categorie" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -653,6 +669,24 @@ "value": "Spedizione" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "Originariamente " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": ", ora " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -819,6 +853,12 @@ "value": "Carta di credito" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "Modulo indirizzo di fatturazione" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -861,6 +901,18 @@ "value": "Sì" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "No, annulla azione" + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "Sì, conferma azione" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -891,10 +943,28 @@ "value": "Sì, rimuovi articolo" } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "No, conserva articolo" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "Rimuovi prodotti non disponibili" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "Sì, rimuovi articolo" + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, - "value": "Alcuni articoli non sono più dispoinibili online e verranno rimossi dal carrello." + "value": "Alcuni articoli non sono più disponibili online e verranno rimossi dal carrello." } ], "confirmation_modal.remove_cart_item.message.sure_to_remove": [ @@ -999,6 +1069,56 @@ "value": "Info codice di sicurezza" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "prezzo attuale " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "A partire dal prezzo attuale " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "prezzo originale " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "A partire dal prezzo originale " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 0, + "value": "Da " + }, + { + "type": 1, + "value": "currentPrice" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1029,6 +1149,12 @@ "value": "Cronologia ordini" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "Cassetto menu" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1417,6 +1543,12 @@ "value": "Menu" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "Apre una finestra di dialogo" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1439,6 +1571,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "Store locator" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1649,6 +1787,12 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "Opzioni selezionate" + } + ], "item_image.label.sale": [ { "type": 0, @@ -1661,10 +1805,32 @@ "value": "Non disponibile" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ { "type": 0, - "value": "A partire da" + "value": "Quantità " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 0, + "value": "Selettore di quantità per " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": ". La quantità selezionata è " + }, + { + "type": 1, + "value": "quantity" } ], "lCPCxk": [ @@ -2489,14 +2655,28 @@ "value": " dalla lista desideri" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { "type": 0, - "value": "A partire da " - }, + "value": "Crea" + } + ], + "product_tile.badge.label.sale": [ { - "type": 1, - "value": "price" + "type": 0, + "value": "Saldi" + } + ], + "product_view.button.add_bundle_to_cart": [ + { + "type": 0, + "value": "Aggiungi bundle al carrello" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "Aggiungi Bundle alla Wishlist" } ], "product_view.button.add_set_to_cart": [ @@ -2532,13 +2712,21 @@ "product_view.label.assistive_msg.quantity_decrement": [ { "type": 0, - "value": "Riduci quantità" + "value": "Riduci quantità per " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.assistive_msg.quantity_increment": [ { "type": 0, - "value": "Incrementa quantità" + "value": "Aumenta quantità per " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.quantity": [ @@ -2559,12 +2747,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "A partire da" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2771,6 +2953,32 @@ "value": "Passa al metodo di spedizione" } ], + "shipping_address.label.edit_button": [ + { + "type": 0, + "value": "Modifica " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 0, + "value": "Rimuovi " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "Modulo indirizzo di spedizione" + } + ], "shipping_address.title.shipping_address": [ { "type": 0, @@ -2861,6 +3069,144 @@ "value": "Uscire? Per procedere con l'ordine corrente devi eseguire di nuovo l'accesso." } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "Trova" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "Seleziona un Paese" + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "Usa la mia posizione" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "Visualizza altri" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "di distanza" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "Caricamento posizioni..." + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "Siamo spiacenti, non ci sono sedi in quest'area" + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "Oppure" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "Telefono:" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 0, + "value": "Visualizzazione dei negozi entro " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 0, + "value": " " + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " da " + }, + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": " in:" + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "Visualizzazione dei negozi vicino alla tua posizione" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "Germania" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "Stati Uniti" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "Accetta di condividere la tua posizione" + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "Inserisci un codice postale." + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "Seleziona un Paese." + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "Inserisci codice postale" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "Carica altri" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "Trova un negozio" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2877,6 +3223,30 @@ "value": "Modifica" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "Modifica informazioni di contatto" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "Modifica informazioni di pagamento" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "Modifica indirizzo di spedizione" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "Modifica opzioni di spedizione" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -2904,7 +3274,7 @@ "use_address_fields.error.please_enter_your_postal_or_zip": [ { "type": 0, - "value": "Inserisci il codice postale." + "value": "Inserisci il tuo codice postale." } ], "use_address_fields.error.please_select_your_address": [ @@ -2928,7 +3298,7 @@ "use_address_fields.error.please_select_your_state_or_province": [ { "type": 0, - "value": "Seleziona lo stato/la provincia." + "value": "Seleziona il tuo stato." } ], "use_address_fields.error.required": [ @@ -3137,12 +3507,44 @@ "value": " rimasti!" } ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 0, + "value": "Solo " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": " rimasti per " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "!" + } + ], "use_product.message.out_of_stock": [ { "type": 0, "value": "Esaurito" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 0, + "value": "Esaurito per " + }, + { + "type": 1, + "value": "productName" + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3260,7 +3662,7 @@ "use_registration_fields.error.required_password": [ { "type": 0, - "value": "Creare una password." + "value": "Crea una password." } ], "use_registration_fields.error.special_character": [ @@ -3371,6 +3773,34 @@ "value": "Nuova password" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 0, + "value": "Aggiungi set " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " al carrello" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 0, + "value": "Aggiungi " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " al carrello" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3383,6 +3813,16 @@ "value": "Aggiungi al carrello" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 0, + "value": "Mostra tutti i dettagli per " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3395,6 +3835,16 @@ "value": "Visualizza opzioni" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 0, + "value": "Visualizza opzioni per " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3439,6 +3889,16 @@ "value": "Rimuovi" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 0, + "value": "Rimuovi " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/ja-JP.json b/packages/template-retail-react-app/app/static/translations/compiled/ja-JP.json index 64323d1040..8cb8cf1161 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/ja-JP.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/ja-JP.json @@ -437,6 +437,16 @@ "value": "買い物カゴから商品が削除されました" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " のモーダルを編集" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -539,6 +549,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "カテゴリ" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -653,6 +669,24 @@ "value": "配送" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "元の価格は " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": " だが、現在は " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -819,6 +853,12 @@ "value": "クレジットカード" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "請求先住所フォーム" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -861,6 +901,18 @@ "value": "はい" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "いいえ、操作をキャンセルします" + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "はい、操作を確認します" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -891,6 +943,24 @@ "value": "はい、商品を削除します" } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "いいえ、商品をキープします" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "入手不可の商品を削除" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "はい、商品を削除します" + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, @@ -999,6 +1069,64 @@ "value": "セキュリティコード情報" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "現在の価格 " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "現在の価格 " + }, + { + "type": 1, + "value": "currentPrice" + }, + { + "type": 0, + "value": " から" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "元の価格 " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "元の価格 " + }, + { + "type": 1, + "value": "listPrice" + }, + { + "type": 0, + "value": " から" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 1, + "value": "currentPrice" + }, + { + "type": 0, + "value": " から" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1029,6 +1157,12 @@ "value": "注文履歴" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "ドロワーメニュー" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1413,6 +1547,12 @@ "value": "メニュー" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "ダイアログを開く" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1435,6 +1575,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "店舗検索" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1645,6 +1791,12 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "選択したオプション" + } + ], "item_image.label.sale": [ { "type": 0, @@ -1657,10 +1809,32 @@ "value": "入手不可" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ + { + "type": 0, + "value": "数量 " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "の数量セレクター。選択された数量は " + }, + { + "type": 1, + "value": "quantity" + }, { "type": 0, - "value": "最低価格" + "value": " です" } ], "lCPCxk": [ @@ -2473,14 +2647,28 @@ "value": " をほしい物リストから削除" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { "type": 0, - "value": "最低価格: " - }, + "value": "新規" + } + ], + "product_tile.badge.label.sale": [ { - "type": 1, - "value": "price" + "type": 0, + "value": "セール" + } + ], + "product_view.button.add_bundle_to_cart": [ + { + "type": 0, + "value": "バンドルを買い物カゴに追加" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "バンドルをほしい物リストに追加" } ], "product_view.button.add_set_to_cart": [ @@ -2514,15 +2702,23 @@ } ], "product_view.label.assistive_msg.quantity_decrement": [ + { + "type": 1, + "value": "productName" + }, { "type": 0, - "value": "数量を減らす" + "value": " の数量を減らす" } ], "product_view.label.assistive_msg.quantity_increment": [ + { + "type": 1, + "value": "productName" + }, { "type": 0, - "value": "数量を増やす" + "value": " の数量を増やす" } ], "product_view.label.quantity": [ @@ -2543,12 +2739,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "最低価格" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2682,7 +2872,7 @@ }, { "type": 0, - "value": "にご同意いただいたものと見なされます" + "value": "にご同意いただいたものと見なされます。" } ], "register_form.message.already_have_account": [ @@ -2783,6 +2973,32 @@ "value": "配送方法に進む" } ], + "shipping_address.label.edit_button": [ + { + "type": 1, + "value": "address" + }, + { + "type": 0, + "value": " の編集" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 1, + "value": "address" + }, + { + "type": 0, + "value": " の削除" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "配送先住所フォーム" + } + ], "shipping_address.title.shipping_address": [ { "type": 0, @@ -2873,6 +3089,140 @@ "value": "サインアウトしますか?現在のご注文を処理するには、再度サインインする必要があります。" } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "検索" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "国を選択してください" + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "現在地を使用" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "もっと見る" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "の距離" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "位置情報を読み込んでいます..." + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "申し訳ございませんが、このエリアには店舗がありません" + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "または" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "電話:" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 0, + "value": "次の " + }, + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": " から " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " 以内の店舗を表示しています: " + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "現在地の近くの店舗を表示しています" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "ドイツ" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "米国" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "現在地を共有することに同意してください" + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "郵便番号を入力してください。" + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "国を選択してください。" + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "郵便番号を入力してください" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "さらに読み込む" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "店舗の検索" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2889,6 +3239,30 @@ "value": "編集" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "連絡先情報の編集" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "支払情報の編集" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "配送先住所の編集" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "配送オプションの編集" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -3146,7 +3520,25 @@ }, { "type": 0, - "value": " 点!" + "value": " 点のみ!" + } + ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " は残り " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": " 点のみ!" } ], "use_product.message.out_of_stock": [ @@ -3155,6 +3547,16 @@ "value": "在庫切れ" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " は在庫切れです" + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3383,6 +3785,26 @@ "value": "新しいパスワード:" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " のセットを買い物カゴに追加" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " を買い物カゴに追加" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3395,6 +3817,16 @@ "value": "買い物カゴに追加" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " の詳細を表示" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3407,6 +3839,16 @@ "value": "オプションを表示" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " のオプションを表示" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3451,6 +3893,16 @@ "value": "削除" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " の削除" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/ko-KR.json b/packages/template-retail-react-app/app/static/translations/compiled/ko-KR.json index f0f158630c..6cce9d5bd6 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/ko-KR.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/ko-KR.json @@ -429,6 +429,16 @@ "value": "항목이 카트에서 제거됨" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "에 대한 모달 편집" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -531,6 +541,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "카테고리" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -645,6 +661,24 @@ "value": "배송" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "원래 가격: " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": " , 현재 가격: " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -807,6 +841,12 @@ "value": "신용카드" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "청구 주소 양식" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -849,6 +889,18 @@ "value": "예" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "아니요, 작업을 취소합니다." + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "예, 작업을 확인합니다" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -879,6 +931,24 @@ "value": "예. 항목을 제거합니다." } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "아니요. 항목을 그대로 둡니다." + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "사용할 수 없는 제품 제거" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "예. 항목을 제거합니다." + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, @@ -987,6 +1057,64 @@ "value": "보안 코드 정보" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "현재 가격 " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "현재 가격 " + }, + { + "type": 1, + "value": "currentPrice" + }, + { + "type": 0, + "value": "에서" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "원래 가격 " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "원래 가격 " + }, + { + "type": 1, + "value": "listPrice" + }, + { + "type": 0, + "value": "에서" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 1, + "value": "currentPrice" + }, + { + "type": 0, + "value": "부터 시작" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1017,6 +1145,12 @@ "value": "주문 내역" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "메뉴 서랍" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1393,6 +1527,12 @@ "value": "메뉴" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "대화창 열기" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1415,6 +1555,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "매장 찾기" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1625,6 +1771,12 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "선택한 옵션" + } + ], "item_image.label.sale": [ { "type": 0, @@ -1637,10 +1789,32 @@ "value": "사용 불가" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ { "type": 0, - "value": "시작가" + "value": "수량 " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "에 대한 수량 선택기 선택한 수량은 " + }, + { + "type": 1, + "value": "quantity" + }, + { + "type": 0, + "value": "개입니다." } ], "lCPCxk": [ @@ -2465,14 +2639,28 @@ "value": " 제거" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { "type": 0, - "value": "시작가: " - }, + "value": "신규" + } + ], + "product_tile.badge.label.sale": [ { - "type": 1, - "value": "price" + "type": 0, + "value": "판매" + } + ], + "product_view.button.add_bundle_to_cart": [ + { + "type": 0, + "value": "카트에 번들 추가" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "위시리스트에 번들 추가" } ], "product_view.button.add_set_to_cart": [ @@ -2506,15 +2694,23 @@ } ], "product_view.label.assistive_msg.quantity_decrement": [ + { + "type": 1, + "value": "productName" + }, { "type": 0, - "value": "수량 줄이기" + "value": "의 감소 수량" } ], "product_view.label.assistive_msg.quantity_increment": [ + { + "type": 1, + "value": "productName" + }, { "type": 0, - "value": "수량 늘리기" + "value": "에 대한 증분 수량" } ], "product_view.label.quantity": [ @@ -2535,12 +2731,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "시작가" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2652,7 +2842,7 @@ "children": [ { "type": 0, - "value": "개인정보보호 정책" + "value": "개인정보 보호정책" } ], "type": 8, @@ -2660,13 +2850,13 @@ }, { "type": 0, - "value": "과 " + "value": " 및 " }, { "children": [ { "type": 0, - "value": "이용 약관" + "value": "약관" } ], "type": 8, @@ -2674,7 +2864,7 @@ }, { "type": 0, - "value": "에 동의한 것으로 간주됩니다." + "value": "에 동의하는 것입니다." } ], "register_form.message.already_have_account": [ @@ -2771,6 +2961,32 @@ "value": "배송 방법으로 계속 진행하기" } ], + "shipping_address.label.edit_button": [ + { + "type": 1, + "value": "address" + }, + { + "type": 0, + "value": " 편집" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 1, + "value": "address" + }, + { + "type": 0, + "value": " 제거" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "배송 주소 양식" + } + ], "shipping_address.title.shipping_address": [ { "type": 0, @@ -2861,6 +3077,136 @@ "value": "로그아웃하시겠습니까? 현재 주문을 처리하려면 다시 로그인해야 합니다." } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "찾기" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "국가 선택" + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "내 위치 사용" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "자세히 보기" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "떨어진 곳에 위치" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "위치 로드 중..." + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "죄송하지만 이 지역에는 위치가 없습니다." + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "Or" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "전화번호:" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": "에서 " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " 내에 위치한 매장 보기" + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "현재 위치에서 가까운 매장 보기" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "독일" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "미국" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "위치 공유에 동의하십시오." + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "우편번호를 입력해 주세요." + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "국가를 선택하십시오." + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "우편번호 입력" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "추가 로드" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "매장 찾기" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2877,6 +3223,30 @@ "value": "편집" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "연락처 정보 편집" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "결제 정보 편집" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "배송 주소 편집" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "배송 옵션 편집" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -2928,7 +3298,7 @@ "use_address_fields.error.please_select_your_state_or_province": [ { "type": 0, - "value": "시/도를 선택하십시오." + "value": "주를 선택하십시오." } ], "use_address_fields.error.required": [ @@ -3137,12 +3507,40 @@ "value": "개 남음)" } ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "이(가) " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": "개 남았습니다!" + } + ], "use_product.message.out_of_stock": [ { "type": 0, "value": "품절" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "이(가) 품절입니다." + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3371,6 +3769,34 @@ "value": "새 암호" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 0, + "value": "카트에 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 세트 추가" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 0, + "value": "카트에 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 추가" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3383,6 +3809,16 @@ "value": "카트에 추가" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "에 대한 전체 세부 정보 보기" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3395,6 +3831,16 @@ "value": "옵션 보기" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "에 대한 보기 옵션" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3439,6 +3885,16 @@ "value": "제거" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 제거" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/pt-BR.json b/packages/template-retail-react-app/app/static/translations/compiled/pt-BR.json index bd59d8c0c6..7a5bc4adde 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/pt-BR.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/pt-BR.json @@ -437,6 +437,16 @@ "value": "Item removido do carrinho" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 0, + "value": "Editar modal para " + }, + { + "type": 1, + "value": "productName" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -539,6 +549,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "Categorias" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -653,6 +669,24 @@ "value": "Frete" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "Originalmente " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": ", agora " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -823,6 +857,12 @@ "value": "Cartão de crédito" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "Formulário de endereço para faturamento" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -865,6 +905,18 @@ "value": "Sim" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "Não, cancelar ação" + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "Sim, confirmar ação" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -895,6 +947,24 @@ "value": "Sim, remover item" } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "Não, manter item" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "Remover produtos indisponíveis" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "Sim, remover item" + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, @@ -1003,6 +1073,56 @@ "value": "Informações do código de segurança" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "preço atual " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "A partir do preço atual " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "preço original " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "A partir do preço original " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 0, + "value": "De " + }, + { + "type": 1, + "value": "currentPrice" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1033,6 +1153,12 @@ "value": "Histórico de pedidos" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "Gaveta de menu" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1048,7 +1174,7 @@ "drawer_menu.link.customer_support.contact_us": [ { "type": 0, - "value": "Entrar em contato" + "value": "Entre em contato" } ], "drawer_menu.link.customer_support.shipping_and_returns": [ @@ -1421,6 +1547,12 @@ "value": "Menu" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "Abre uma caixa de diálogo" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1443,6 +1575,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "Localizador de lojas" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1653,6 +1791,12 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "Opções selecionadas" + } + ], "item_image.label.sale": [ { "type": 0, @@ -1665,10 +1809,32 @@ "value": "Indisponível" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ { "type": 0, - "value": "A partir de" + "value": "Quantidade " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 0, + "value": "Seletor de quantidade para " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": ". A quantidade selecionada é " + }, + { + "type": 1, + "value": "quantity" } ], "lCPCxk": [ @@ -2493,14 +2659,28 @@ "value": " da lista de desejos" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { "type": 0, - "value": "A partir de " - }, + "value": "Criar" + } + ], + "product_tile.badge.label.sale": [ { - "type": 1, - "value": "price" + "type": 0, + "value": "Promoção" + } + ], + "product_view.button.add_bundle_to_cart": [ + { + "type": 0, + "value": "Adicionar pacote ao carrinho" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "Adicionar pacote à lista de desejos" } ], "product_view.button.add_set_to_cart": [ @@ -2536,13 +2716,21 @@ "product_view.label.assistive_msg.quantity_decrement": [ { "type": 0, - "value": "Quantidade de decremento" + "value": "Quantidade em decremento para " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.assistive_msg.quantity_increment": [ { "type": 0, - "value": "Quantidade de incremento" + "value": "Quantidade em incremento para " + }, + { + "type": 1, + "value": "productName" } ], "product_view.label.quantity": [ @@ -2563,12 +2751,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "A partir de" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2803,6 +2985,32 @@ "value": "Ir ao método de entrega" } ], + "shipping_address.label.edit_button": [ + { + "type": 0, + "value": "Editar " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 0, + "value": "Remover " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "Formulário de endereço de entrega" + } + ], "shipping_address.title.shipping_address": [ { "type": 0, @@ -2893,6 +3101,140 @@ "value": "Tem certeza de que deseja fazer logout? Será preciso fazer logon novamente para dar continuidade ao seu pedido atual." } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "Localizar" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "Selecione um país" + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "Utilizar a minha localização" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "Ver mais" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "de distância" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "Carregando localizações..." + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "Desculpe, não há localizações nesta área" + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "Ou" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "Telefone:" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 0, + "value": "Visualizando lojas dentro de " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " de " + }, + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": " em" + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "Ver lojas perto da sua localização" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "Alemanha" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "Estados Unidos" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "Aceite compartilhar sua localização" + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "Insira um código postal." + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "Selecione um país." + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "Inserir código postal" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "Carregar mais" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "Encontre uma loja" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2909,6 +3251,30 @@ "value": "Editar" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "Editar informações de contato" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "Editar informações de pagamento" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "Editar endereço de entrega" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "Editar opções de envio" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -2936,7 +3302,7 @@ "use_address_fields.error.please_enter_your_postal_or_zip": [ { "type": 0, - "value": "Insira seu código postal." + "value": "Insira seu CEP." } ], "use_address_fields.error.please_select_your_address": [ @@ -2960,7 +3326,7 @@ "use_address_fields.error.please_select_your_state_or_province": [ { "type": 0, - "value": "Selecione estado/província." + "value": "Selecione seu estado." } ], "use_address_fields.error.required": [ @@ -3169,12 +3535,44 @@ "value": " restante(s)!" } ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 0, + "value": "Sobraram somente " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": " para " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "!" + } + ], "use_product.message.out_of_stock": [ { "type": 0, "value": "Fora de estoque" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " esgotado(a)" + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3403,6 +3801,34 @@ "value": "Nova senha" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 0, + "value": "Adicionar conjunto de " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " ao carrinho" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 0, + "value": "Adicionar " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " ao carrinho" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3415,6 +3841,16 @@ "value": "Adicionar ao carrinho" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 0, + "value": "Ver todos os detalhes de " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3427,6 +3863,16 @@ "value": "Ver opções" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 0, + "value": "Ver opções para " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3471,6 +3917,16 @@ "value": "Remover" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 0, + "value": "Remover " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/zh-CN.json b/packages/template-retail-react-app/app/static/translations/compiled/zh-CN.json index d406c55c72..f81152f55c 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/zh-CN.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/zh-CN.json @@ -437,6 +437,20 @@ "value": "从购物车中移除商品" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 0, + "value": "编辑 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 模态" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -539,6 +553,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "类别" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -653,6 +673,24 @@ "value": "送货" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "原价 " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": ",现价 " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -819,6 +857,12 @@ "value": "信用卡" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "帐单地址表格" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -861,6 +905,18 @@ "value": "是" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "否,取消操作" + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "是,确认操作" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -891,6 +947,24 @@ "value": "是,移除商品" } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "否,保留商品" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "移除无货产品" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "是,移除商品" + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, @@ -999,6 +1073,60 @@ "value": "安全码信息" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "当前价格 " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "从当前价格 " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "原价 " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "从原价 " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 0, + "value": "从 " + }, + { + "type": 1, + "value": "currentPrice" + }, + { + "type": 0, + "value": " 起" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1029,6 +1157,12 @@ "value": "订单记录" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "菜单抽屉" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1417,6 +1551,12 @@ "value": "菜单" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "打开对话框" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1439,6 +1579,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "实体店地址搜索" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1649,6 +1795,12 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "已选选项" + } + ], "item_image.label.sale": [ { "type": 0, @@ -1661,10 +1813,28 @@ "value": "不可用" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ + { + "type": 0, + "value": "数量 " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 1, + "value": "productName" + }, { "type": 0, - "value": "起价:" + "value": " 的数量选择器。选择的数量是 " + }, + { + "type": 1, + "value": "quantity" } ], "lCPCxk": [ @@ -2485,14 +2655,28 @@ "value": "product" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { "type": 0, - "value": "起价:" - }, + "value": "新建" + } + ], + "product_tile.badge.label.sale": [ { - "type": 1, - "value": "price" + "type": 0, + "value": "销售" + } + ], + "product_view.button.add_bundle_to_cart": [ + { + "type": 0, + "value": "将套装添加到购物车" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "将套装添加到心愿单" } ], "product_view.button.add_set_to_cart": [ @@ -2528,13 +2712,29 @@ "product_view.label.assistive_msg.quantity_decrement": [ { "type": 0, - "value": "递减数量" + "value": "递减 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 数量" } ], "product_view.label.assistive_msg.quantity_increment": [ { "type": 0, - "value": "递增数量" + "value": "递增 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 数量" } ], "product_view.label.quantity": [ @@ -2555,12 +2755,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "起价:" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2666,7 +2860,7 @@ "register_form.message.agree_to_policy_terms": [ { "type": 0, - "value": "创建账户即表明您同意 Salesforce " + "value": "创建帐户即表示您同意 Salesforce " }, { "children": [ @@ -2680,7 +2874,7 @@ }, { "type": 0, - "value": "以及" + "value": "和" }, { "children": [ @@ -2791,6 +2985,32 @@ "value": "继续并选择送货方式" } ], + "shipping_address.label.edit_button": [ + { + "type": 0, + "value": "编辑 " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 0, + "value": "移除" + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "送货地址表格" + } + ], "shipping_address.title.shipping_address": [ { "type": 0, @@ -2881,6 +3101,140 @@ "value": "是否确定要注销?您需要重新登录才能继续处理当前订单。" } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "查找" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "选择国家/地区" + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "使用我的位置" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "查看更多" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "離開" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "正在加载位置..." + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "对不起,这个区域没有位置" + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "或" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "电话:" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 0, + "value": "查看查看距离 " + }, + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": " " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " 内的实体店" + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "查看您所在位置附近的实体店" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "德国" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "美国" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "请同意分享您的所在位置" + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "请输入邮政编码。" + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "请选择国家。" + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "输入邮政编码" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "加载更多" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "查找实体店" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2897,6 +3251,30 @@ "value": "编辑" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "编辑联系信息" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "编辑付款信息" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "编辑送货地址" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "编辑送货选项" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -2948,7 +3326,7 @@ "use_address_fields.error.please_select_your_state_or_province": [ { "type": 0, - "value": "请选择您所在的州/省。" + "value": "请选择您所在的州。" } ], "use_address_fields.error.required": [ @@ -3157,12 +3535,40 @@ "value": " 件!" } ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 只剩下 " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": "!" + } + ], "use_product.message.out_of_stock": [ { "type": 0, "value": "无库存" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 无库存" + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3391,6 +3797,34 @@ "value": "新密码" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 0, + "value": "将 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 套装添加到购物车" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 0, + "value": "将 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 添加到购物车" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3403,6 +3837,20 @@ "value": "添加到购物车" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 0, + "value": "查看 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 的完整详细信息" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3415,6 +3863,20 @@ "value": "查看选项" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 0, + "value": "查看 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 的选项" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3459,6 +3921,16 @@ "value": "移除" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 0, + "value": "移除" + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/static/translations/compiled/zh-TW.json b/packages/template-retail-react-app/app/static/translations/compiled/zh-TW.json index 3877030193..1702e03af2 100644 --- a/packages/template-retail-react-app/app/static/translations/compiled/zh-TW.json +++ b/packages/template-retail-react-app/app/static/translations/compiled/zh-TW.json @@ -433,6 +433,16 @@ "value": "已從購物車移除商品" } ], + "cart.product_edit_modal.modal_label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 的編輯互動視窗 (modal)" + } + ], "cart.recommended_products.title.may_also_like": [ { "type": 0, @@ -535,6 +545,12 @@ "value": ")" } ], + "category_links.button_text": [ + { + "type": 0, + "value": "類別" + } + ], "cc_radio_group.action.remove": [ { "type": 0, @@ -649,6 +665,24 @@ "value": "運送" } ], + "checkout_confirmation.label.shipping.strikethrough.price": [ + { + "type": 0, + "value": "原本 " + }, + { + "type": 1, + "value": "originalPrice" + }, + { + "type": 0, + "value": " ,現在 " + }, + { + "type": 1, + "value": "newPrice" + } + ], "checkout_confirmation.label.subtotal": [ { "type": 0, @@ -815,6 +849,12 @@ "value": "信用卡" } ], + "checkout_payment.label.billing_address_form": [ + { + "type": 0, + "value": "帳單地址表單" + } + ], "checkout_payment.label.same_as_shipping": [ { "type": 0, @@ -857,6 +897,18 @@ "value": "是" } ], + "confirmation_modal.default.assistive_msg.no": [ + { + "type": 0, + "value": "否,取消動作" + } + ], + "confirmation_modal.default.assistive_msg.yes": [ + { + "type": 0, + "value": "是,確認動作" + } + ], "confirmation_modal.default.message.you_want_to_continue": [ { "type": 0, @@ -887,6 +939,24 @@ "value": "是,移除商品" } ], + "confirmation_modal.remove_cart_item.assistive_msg.no": [ + { + "type": 0, + "value": "否,保留商品" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.remove": [ + { + "type": 0, + "value": "移除無法提供的產品" + } + ], + "confirmation_modal.remove_cart_item.assistive_msg.yes": [ + { + "type": 0, + "value": "是,移除商品" + } + ], "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": [ { "type": 0, @@ -995,6 +1065,56 @@ "value": "安全碼資訊" } ], + "display_price.assistive_msg.current_price": [ + { + "type": 0, + "value": "目前價格 " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.current_price_with_range": [ + { + "type": 0, + "value": "從目前價格 " + }, + { + "type": 1, + "value": "currentPrice" + } + ], + "display_price.assistive_msg.strikethrough_price": [ + { + "type": 0, + "value": "原價 " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.assistive_msg.strikethrough_price_with_range": [ + { + "type": 0, + "value": "從原價 " + }, + { + "type": 1, + "value": "listPrice" + } + ], + "display_price.label.current_price_with_range": [ + { + "type": 0, + "value": "從 " + }, + { + "type": 1, + "value": "currentPrice" + } + ], "drawer_menu.button.account_details": [ { "type": 0, @@ -1025,6 +1145,12 @@ "value": "訂單記錄" } ], + "drawer_menu.header.assistive_msg.title": [ + { + "type": 0, + "value": "隱藏式側選單" + } + ], "drawer_menu.link.about_us": [ { "type": 0, @@ -1413,6 +1539,12 @@ "value": "選單" } ], + "header.button.assistive_msg.menu.open_dialog": [ + { + "type": 0, + "value": "開啟對話方塊" + } + ], "header.button.assistive_msg.my_account": [ { "type": 0, @@ -1435,6 +1567,12 @@ "value": "numItems" } ], + "header.button.assistive_msg.store_locator": [ + { + "type": 0, + "value": "商店位置搜尋" + } + ], "header.button.assistive_msg.wishlist": [ { "type": 0, @@ -1645,6 +1783,12 @@ "value": "quantity" } ], + "item_attributes.label.selected_options": [ + { + "type": 0, + "value": "已選取的選項" + } + ], "item_image.label.sale": [ { "type": 0, @@ -1657,10 +1801,28 @@ "value": "不可用" } ], - "item_price.label.starting_at": [ + "item_variant.assistive_msg.quantity": [ { "type": 0, - "value": "起始" + "value": "數量 " + }, + { + "type": 1, + "value": "quantity" + } + ], + "item_variant.quantity.label": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 的數量選擇器 。 選擇的數量是 " + }, + { + "type": 1, + "value": "quantity" } ], "lCPCxk": [ @@ -2481,14 +2643,28 @@ "value": "product" } ], - "product_tile.label.starting_at_price": [ + "product_tile.badge.label.new": [ { - "type": 1, - "value": "price" - }, + "type": 0, + "value": "新增" + } + ], + "product_tile.badge.label.sale": [ + { + "type": 0, + "value": "特價" + } + ], + "product_view.button.add_bundle_to_cart": [ { "type": 0, - "value": " 起" + "value": "新增搭售方案到購物車" + } + ], + "product_view.button.add_bundle_to_wishlist": [ + { + "type": 0, + "value": "新增搭售方案到願望清單" } ], "product_view.button.add_set_to_cart": [ @@ -2522,15 +2698,23 @@ } ], "product_view.label.assistive_msg.quantity_decrement": [ + { + "type": 1, + "value": "productName" + }, { "type": 0, - "value": "遞減數量" + "value": " 的遞減數量" } ], "product_view.label.assistive_msg.quantity_increment": [ + { + "type": 1, + "value": "productName" + }, { "type": 0, - "value": "遞增數量" + "value": " 的遞增數量" } ], "product_view.label.quantity": [ @@ -2551,12 +2735,6 @@ "value": "+" } ], - "product_view.label.starting_at_price": [ - { - "type": 0, - "value": "起始" - } - ], "product_view.label.variant_type": [ { "type": 1, @@ -2784,7 +2962,33 @@ "shipping_address.button.continue_to_shipping": [ { "type": 0, - "value": "繼續前往運送方式" + "value": "繼續前往送貨方式" + } + ], + "shipping_address.label.edit_button": [ + { + "type": 0, + "value": "編輯 " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.remove_button": [ + { + "type": 0, + "value": "移除 " + }, + { + "type": 1, + "value": "address" + } + ], + "shipping_address.label.shipping_address_form": [ + { + "type": 0, + "value": "送貨地址表單" } ], "shipping_address.title.shipping_address": [ @@ -2877,6 +3081,144 @@ "value": "確定要登出嗎?您必須重新登入,才能繼續目前的訂單流程。" } ], + "store_locator.action.find": [ + { + "type": 0, + "value": "尋找" + } + ], + "store_locator.action.select_a_country": [ + { + "type": 0, + "value": "選擇國家/地區" + } + ], + "store_locator.action.use_my_location": [ + { + "type": 0, + "value": "使用我的位置" + } + ], + "store_locator.action.viewMore": [ + { + "type": 0, + "value": "檢視更多" + } + ], + "store_locator.description.away": [ + { + "type": 0, + "value": "離開" + } + ], + "store_locator.description.loading_locations": [ + { + "type": 0, + "value": "載入位置..." + } + ], + "store_locator.description.no_locations": [ + { + "type": 0, + "value": "對不起,此區域沒有位置" + } + ], + "store_locator.description.or": [ + { + "type": 0, + "value": "或" + } + ], + "store_locator.description.phone": [ + { + "type": 0, + "value": "電話:" + } + ], + "store_locator.description.viewing_near_postal_code": [ + { + "type": 0, + "value": "檢視在 " + }, + { + "type": 1, + "value": "postalCode" + }, + { + "type": 0, + "value": " 的 " + }, + { + "type": 1, + "value": "distance" + }, + { + "type": 0, + "value": " " + }, + { + "type": 1, + "value": "distanceUnit" + }, + { + "type": 0, + "value": " 商店" + } + ], + "store_locator.description.viewing_near_your_location": [ + { + "type": 0, + "value": "檢視您所在附近的商店位置" + } + ], + "store_locator.dropdown.germany": [ + { + "type": 0, + "value": "德國" + } + ], + "store_locator.dropdown.united_states": [ + { + "type": 0, + "value": "美國" + } + ], + "store_locator.error.agree_to_share_your_location": [ + { + "type": 0, + "value": "請同意分享您的位置" + } + ], + "store_locator.error.please_enter_a_postal_code": [ + { + "type": 0, + "value": "請輸入郵遞區號。" + } + ], + "store_locator.error.please_select_a_country": [ + { + "type": 0, + "value": "請選擇國家/地區。" + } + ], + "store_locator.field.placeholder.enter_postal_code": [ + { + "type": 0, + "value": "輸入郵遞區號" + } + ], + "store_locator.pagination.load_more": [ + { + "type": 0, + "value": "載入更多" + } + ], + "store_locator.title": [ + { + "type": 0, + "value": "尋找商店" + } + ], "swatch_group.selected.label": [ { "type": 1, @@ -2893,6 +3235,30 @@ "value": "編輯" } ], + "toggle_card.action.editContactInfo": [ + { + "type": 0, + "value": "編輯聯絡資訊" + } + ], + "toggle_card.action.editPaymentInfo": [ + { + "type": 0, + "value": "編輯付款資訊" + } + ], + "toggle_card.action.editShippingAddress": [ + { + "type": 0, + "value": "編輯運送地址" + } + ], + "toggle_card.action.editShippingOptions": [ + { + "type": 0, + "value": "編輯運送選項" + } + ], "update_password_fields.button.forgot_password": [ { "type": 0, @@ -2944,7 +3310,7 @@ "use_address_fields.error.please_select_your_state_or_province": [ { "type": 0, - "value": "請選擇您的州/省。" + "value": "請選擇您所在的州。" } ], "use_address_fields.error.required": [ @@ -3153,12 +3519,40 @@ "value": " 個!" } ], + "use_product.message.inventory_remaining_for_product": [ + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": "只剩下 " + }, + { + "type": 1, + "value": "stockLevel" + }, + { + "type": 0, + "value": "!" + } + ], "use_product.message.out_of_stock": [ { "type": 0, "value": "缺貨" } ], + "use_product.message.out_of_stock_for_product": [ + { + "type": 0, + "value": "缺貨 " + }, + { + "type": 1, + "value": "productName" + } + ], "use_profile_fields.error.required_email": [ { "type": 0, @@ -3387,6 +3781,34 @@ "value": "新密碼" } ], + "wishlist_primary_action.button.addSetToCart.label": [ + { + "type": 0, + "value": "新增 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 組合至購物車" + } + ], + "wishlist_primary_action.button.addToCart.label": [ + { + "type": 0, + "value": "新增 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 至購物車" + } + ], "wishlist_primary_action.button.add_set_to_cart": [ { "type": 0, @@ -3399,6 +3821,20 @@ "value": "新增至購物車" } ], + "wishlist_primary_action.button.viewFullDetails.label": [ + { + "type": 0, + "value": "檢視 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 完整詳細資訊" + } + ], "wishlist_primary_action.button.view_full_details": [ { "type": 0, @@ -3411,6 +3847,20 @@ "value": "檢視選項" } ], + "wishlist_primary_action.button.view_options.label": [ + { + "type": 0, + "value": "檢視 " + }, + { + "type": 1, + "value": "productName" + }, + { + "type": 0, + "value": " 的選項" + } + ], "wishlist_primary_action.info.added_to_cart": [ { "type": 1, @@ -3455,6 +3905,16 @@ "value": "移除" } ], + "wishlist_secondary_button_group.info.item.remove.label": [ + { + "type": 0, + "value": "移除 " + }, + { + "type": 1, + "value": "productName" + } + ], "wishlist_secondary_button_group.info.item_removed": [ { "type": 0, diff --git a/packages/template-retail-react-app/app/utils/test-utils.js b/packages/template-retail-react-app/app/utils/test-utils.js index c6105b6f37..f9b496e11e 100644 --- a/packages/template-retail-react-app/app/utils/test-utils.js +++ b/packages/template-retail-react-app/app/utils/test-utils.js @@ -20,10 +20,23 @@ import {withReactQuery} from '@salesforce/pwa-kit-react-sdk/ssr/universal/compon import fallbackMessages from '@salesforce/retail-react-app/app/static/translations/compiled/en-GB.json' import mockConfig from '@salesforce/retail-react-app/config/mocks/default' // Contexts -import {CurrencyProvider, MultiSiteProvider} from '@salesforce/retail-react-app/app/contexts' +import { + CurrencyProvider, + MultiSiteProvider, + StoreLocatorProvider +} from '@salesforce/retail-react-app/app/contexts' import {createUrlTemplate} from '@salesforce/retail-react-app/app/utils/url' import {getSiteByReference} from '@salesforce/retail-react-app/app/utils/site-utils' +import { + STORE_LOCATOR_RADIUS, + STORE_LOCATOR_RADIUS_UNIT, + STORE_LOCATOR_DEFAULT_COUNTRY, + STORE_LOCATOR_DEFAULT_COUNTRY_CODE, + STORE_LOCATOR_DEFAULT_POSTAL_CODE, + STORE_LOCATOR_DEFAULT_PAGE_SIZE, + STORE_LOCATOR_SUPPORTED_COUNTRIES +} from '@salesforce/retail-react-app/app/constants' import jwt from 'jsonwebtoken' import userEvent from '@testing-library/user-event' // This JWT's payload is special @@ -120,6 +133,16 @@ export const TestProviders = ({ locale.alias || locale.id ) + const storeLocatorConfig = { + radius: STORE_LOCATOR_RADIUS, + radiusUnit: STORE_LOCATOR_RADIUS_UNIT, + defaultCountry: STORE_LOCATOR_DEFAULT_COUNTRY, + defaultCountryCode: STORE_LOCATOR_DEFAULT_COUNTRY_CODE, + defaultPostalCode: STORE_LOCATOR_DEFAULT_POSTAL_CODE, + defaultPageSize: STORE_LOCATOR_DEFAULT_PAGE_SIZE, + supportedCountries: STORE_LOCATOR_SUPPORTED_COUNTRIES + } + return ( @@ -135,11 +158,13 @@ export const TestProviders = ({ fetchedToken={bypassAuth ? (isGuest ? guestToken : registerUserToken) : ''} > - - - {children} - - + + + + {children} + + + diff --git a/packages/template-retail-react-app/translations/de-DE.json b/packages/template-retail-react-app/translations/de-DE.json index b1f7513a09..bd390f3e6b 100644 --- a/packages/template-retail-react-app/translations/de-DE.json +++ b/packages/template-retail-react-app/translations/de-DE.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "Artikel aus dem Warenkorb entfernt" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "Modales Bearbeitungsfenster für {productName}" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "Das könnte Ihnen auch gefallen" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "Warenkorb ({itemCount, plural, =0 {0 Artikel} one {# Artikel} other {# Artikel}})" }, + "category_links.button_text": { + "defaultMessage": "Kategorien" + }, "cc_radio_group.action.remove": { "defaultMessage": "Entfernen" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "Versand" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "Ursprünglich {originalPrice}, jetzt {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "Zwischensumme" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "Kreditkarte" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "Formular für Rechnungsadresse" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "Entspricht der Lieferadresse" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "Ja" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "Nein, Aktion abbrechen" + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "Ja, Aktion bestätigen" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "Möchten Sie wirklich fortfahren?" }, @@ -349,6 +367,15 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "Ja, Artikel entfernen" }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "Nein, Artikel beibehalten" + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "Nicht verfügbare Produkte entfernen" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "Ja, Artikel entfernen" + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { "defaultMessage": "Einige Artikel sind nicht mehr online verfügbar und werden aus Ihrem Warenkorb entfernt." }, @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "Informationen zum Sicherheitscode" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "aktueller Preis {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "Ab aktuellem Preis {currentPrice}" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "ursprünglicher Preis {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "Ab ursprünglichem Preis {listPrice}" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "Von {currentPrice}" + }, "drawer_menu.button.account_details": { "defaultMessage": "Kontodetails" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "Bestellverlauf" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "Menü-Drawer" + }, "drawer_menu.link.about_us": { "defaultMessage": "Über uns" }, @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "Menü" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "Öffnet einen Dialog" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "Mein Konto" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "Mein Warenkorb, Anzahl der Artikel: {numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "Shop-Finder" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "Wunschliste" }, @@ -691,6 +742,9 @@ "item_attributes.label.quantity": { "defaultMessage": "Menge: {quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "Ausgewählte Optionen" + }, "item_image.label.sale": { "defaultMessage": "Sonderangebot", "description": "A sale badge placed on top of a product image" @@ -699,8 +753,11 @@ "defaultMessage": "Nicht verfügbar", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "Ab" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "Menge {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "Mengenauswahl für {productName}. Die gewählte Menge ist {quantity}" }, "lCPCxk": { "defaultMessage": "Bitte alle Optionen oben auswählen" @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "{product} aus der Wunschliste entfernt" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "Ab {price}" + "product_tile.badge.label.new": { + "defaultMessage": "Neu" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "Sonderangebot" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "Bündel in den Warenkorb legen" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "Bündel zur Wunschliste hinzufügen" }, "product_view.button.add_set_to_cart": { "defaultMessage": "Set zum Warenkorb hinzufügen" @@ -1082,10 +1148,10 @@ "defaultMessage": "Aktualisieren" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "Menge verringern" + "defaultMessage": "Menge verringern für {productName}" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "Menge erhöhen" + "defaultMessage": "Menge erhöhen für {productName}" }, "product_view.label.quantity": { "defaultMessage": "Menge" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "Ab" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1151,7 +1214,7 @@ "defaultMessage": "Es kann losgehen!" }, "register_form.message.agree_to_policy_terms": { - "defaultMessage": "Durch das Erstellen eines Kontos stimmen Sie der Datenschutzerklärung und den allgemeinen Geschäftsbedingungen von Salesforce zu." + "defaultMessage": "Durch das Erstellen eines Kontos stimmen Sie der Datenschutzrichtlinie und den Allgemeinen Geschäftsbedingungen von Salesforce zu." }, "register_form.message.already_have_account": { "defaultMessage": "Sie haben bereits ein Konto?" @@ -1196,6 +1259,15 @@ "shipping_address.button.continue_to_shipping": { "defaultMessage": "Weiter zur Versandmethode" }, + "shipping_address.label.edit_button": { + "defaultMessage": "{address} bearbeiten" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "{address} entfernen" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "Formular für die Lieferadresse" + }, "shipping_address.title.shipping_address": { "defaultMessage": "Lieferadresse" }, @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "Möchten Sie sich wirklich abmelden? Sie müssen sich wieder anmelden, um mit Ihrer aktuellen Bestellung fortzufahren." }, + "store_locator.action.find": { + "defaultMessage": "Suchen" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "Land auswählen" + }, + "store_locator.action.use_my_location": { + "defaultMessage": "Meinen Standort verwenden" + }, + "store_locator.action.viewMore": { + "defaultMessage": "Mehr anzeigen" + }, + "store_locator.description.away": { + "defaultMessage": "entfernt" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "Standorte werden geladen …" + }, + "store_locator.description.no_locations": { + "defaultMessage": "Leider gibt es in dieser Gegend keine Standorte." + }, + "store_locator.description.or": { + "defaultMessage": "Oder" + }, + "store_locator.description.phone": { + "defaultMessage": "Telefon:" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "Anzeige von Geschäften innerhalb von {distance} {distanceUnit} von {postalCode} in" + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "Anzeige von Geschäften in der Nähe Ihres Standorts" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "Deutschland" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "USA" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "Bitte stimmen Sie zu, Ihren Standort zu teilen." + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "Bitte geben Sie eine Postleitzahl ein." + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "Bitte wählen Sie ein Land aus." + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "Postleitzahl eingeben" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "Mehr laden" + }, + "store_locator.title": { + "defaultMessage": "Ein Geschäft finden" + }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, "toggle_card.action.edit": { "defaultMessage": "Bearbeiten" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "Kontaktinformationen bearbeiten" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "Zahlungsinformationen bearbeiten" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "Lieferadresse bearbeiten" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "Versandoptionen bearbeiten" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "Passwort vergessen?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "Bitte geben Sie Ihre Telefonnummer ein." }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "Bitte geben Sie Ihre Postleitzahl ein." + "defaultMessage": "Bitte geben Sie Ihre Postleitzahl ein.", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "Bitte geben Sie Ihre Adresse ein." @@ -1272,7 +1414,8 @@ "defaultMessage": "Bitte wählen Sie Ihr Land aus." }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "Bitte wählen Sie Ihr Bundesland aus." + "defaultMessage": "Bitte wählen Sie Ihr Bundesland aus.", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "Erforderlich" @@ -1373,9 +1516,15 @@ "use_product.message.inventory_remaining": { "defaultMessage": "Nur noch {stockLevel} vorhanden!" }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "Nur noch {stockLevel} von {productName} vorhanden!" + }, "use_product.message.out_of_stock": { "defaultMessage": "Nicht vorrätig" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "Nicht vorrätig für {productName}" + }, "use_profile_fields.error.required_email": { "defaultMessage": "Bitte geben Sie eine gültige E-Mail-Adresse ein." }, @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "Neues Passwort" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "{productName}-Set im Warenkorb ablegen" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "{productName} im Warenkorb ablegen" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "Set zum Warenkorb hinzufügen" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "In den Warenkorb" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "Vollständige Details anzeigen für {productName}" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "Alle Einzelheiten anzeigen" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "Optionen anzeigen" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "Optionen anzeigen für {productName}" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one {Artikel} other {Artikel}} zum Warenkorb hinzugefügt" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "Entfernen" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "{productName} entfernen" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "Artikel aus der Wunschliste entfernt" }, diff --git a/packages/template-retail-react-app/translations/en-GB.json b/packages/template-retail-react-app/translations/en-GB.json index c6e5c939e7..34d01ab939 100644 --- a/packages/template-retail-react-app/translations/en-GB.json +++ b/packages/template-retail-react-app/translations/en-GB.json @@ -796,9 +796,6 @@ "icons.assistive_msg.lock": { "defaultMessage": "Secure" }, - "item_attributes.label.is_bonus_product": { - "defaultMessage": "Bonus Product" - }, "item_attributes.label.promotions": { "defaultMessage": "Promotions" }, @@ -1406,63 +1403,6 @@ "social_login_redirect.message.redirect_link": { "defaultMessage": "If you are not automatically redirected, click this link to proceed." }, - "store_locator.action.find": { - "defaultMessage": "Find" - }, - "store_locator.action.select_a_country": { - "defaultMessage": "Select a country" - }, - "store_locator.action.use_my_location": { - "defaultMessage": "Use My Location" - }, - "store_locator.action.viewMore": { - "defaultMessage": "View More" - }, - "store_locator.description.away": { - "defaultMessage": "away" - }, - "store_locator.description.loading_locations": { - "defaultMessage": "Loading locations..." - }, - "store_locator.description.no_locations": { - "defaultMessage": "Sorry, there are no locations in this area" - }, - "store_locator.description.or": { - "defaultMessage": "Or" - }, - "store_locator.description.phone": { - "defaultMessage": "Phone:" - }, - "store_locator.description.viewing_near_postal_code": { - "defaultMessage": "Viewing stores within {distance}{distanceUnit} of {postalCode} in" - }, - "store_locator.description.viewing_near_your_location": { - "defaultMessage": "Viewing stores near your location" - }, - "store_locator.dropdown.germany": { - "defaultMessage": "Germany" - }, - "store_locator.dropdown.united_states": { - "defaultMessage": "United States" - }, - "store_locator.error.agree_to_share_your_location": { - "defaultMessage": "Please agree to share your location" - }, - "store_locator.error.please_enter_a_postal_code": { - "defaultMessage": "Please enter a postal code." - }, - "store_locator.error.please_select_a_country": { - "defaultMessage": "Please select a country." - }, - "store_locator.field.placeholder.enter_postal_code": { - "defaultMessage": "Enter postal code" - }, - "store_locator.pagination.load_more": { - "defaultMessage": "Load More" - }, - "store_locator.title": { - "defaultMessage": "Find a Store" - }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, diff --git a/packages/template-retail-react-app/translations/en-US.json b/packages/template-retail-react-app/translations/en-US.json index c6e5c939e7..34d01ab939 100644 --- a/packages/template-retail-react-app/translations/en-US.json +++ b/packages/template-retail-react-app/translations/en-US.json @@ -796,9 +796,6 @@ "icons.assistive_msg.lock": { "defaultMessage": "Secure" }, - "item_attributes.label.is_bonus_product": { - "defaultMessage": "Bonus Product" - }, "item_attributes.label.promotions": { "defaultMessage": "Promotions" }, @@ -1406,63 +1403,6 @@ "social_login_redirect.message.redirect_link": { "defaultMessage": "If you are not automatically redirected, click this link to proceed." }, - "store_locator.action.find": { - "defaultMessage": "Find" - }, - "store_locator.action.select_a_country": { - "defaultMessage": "Select a country" - }, - "store_locator.action.use_my_location": { - "defaultMessage": "Use My Location" - }, - "store_locator.action.viewMore": { - "defaultMessage": "View More" - }, - "store_locator.description.away": { - "defaultMessage": "away" - }, - "store_locator.description.loading_locations": { - "defaultMessage": "Loading locations..." - }, - "store_locator.description.no_locations": { - "defaultMessage": "Sorry, there are no locations in this area" - }, - "store_locator.description.or": { - "defaultMessage": "Or" - }, - "store_locator.description.phone": { - "defaultMessage": "Phone:" - }, - "store_locator.description.viewing_near_postal_code": { - "defaultMessage": "Viewing stores within {distance}{distanceUnit} of {postalCode} in" - }, - "store_locator.description.viewing_near_your_location": { - "defaultMessage": "Viewing stores near your location" - }, - "store_locator.dropdown.germany": { - "defaultMessage": "Germany" - }, - "store_locator.dropdown.united_states": { - "defaultMessage": "United States" - }, - "store_locator.error.agree_to_share_your_location": { - "defaultMessage": "Please agree to share your location" - }, - "store_locator.error.please_enter_a_postal_code": { - "defaultMessage": "Please enter a postal code." - }, - "store_locator.error.please_select_a_country": { - "defaultMessage": "Please select a country." - }, - "store_locator.field.placeholder.enter_postal_code": { - "defaultMessage": "Enter postal code" - }, - "store_locator.pagination.load_more": { - "defaultMessage": "Load More" - }, - "store_locator.title": { - "defaultMessage": "Find a Store" - }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, diff --git a/packages/template-retail-react-app/translations/es-MX.json b/packages/template-retail-react-app/translations/es-MX.json index 83b1b23661..fe16e2a22e 100644 --- a/packages/template-retail-react-app/translations/es-MX.json +++ b/packages/template-retail-react-app/translations/es-MX.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "Artículo eliminado del carrito" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "Editar modal para {productName}" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "Quizás también te guste" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "Carrito ({itemCount, plural, =0 {0 artículos} one {# artículo} other {# artículos}})" }, + "category_links.button_text": { + "defaultMessage": "Categorías" + }, "cc_radio_group.action.remove": { "defaultMessage": "Eliminar" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "Envío" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "Originalmente {originalPrice}, ahora {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "Subtotal" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "Tarjeta de crédito" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "Formulario de dirección de facturación" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "Misma que la dirección de envío" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "Sí" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "No, cancelar acción" + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "Sí, confirme la acción" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "¿Está seguro de que desea continuar?" }, @@ -349,6 +367,15 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "Sí, eliminar artículo" }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "No, conservar artículo" + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "Eliminar productos no disponibles" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "Sí, eliminar artículo" + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { "defaultMessage": "Algunos artículos ya no están disponibles en línea y se eliminarán de su carrito." }, @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "Información del código de seguridad" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "precio actual {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "A partir del precio actual {currentPrice}" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "precio original {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "Desde el precio original {listPrice}" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "De {currentPrice}" + }, "drawer_menu.button.account_details": { "defaultMessage": "Detalles de la cuenta" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "Historial de pedidos" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "Cajón de menú" + }, "drawer_menu.link.about_us": { "defaultMessage": "Acerca de nosotros" }, @@ -445,7 +490,7 @@ "defaultMessage": "Comprar todo" }, "drawer_menu.link.sign_in": { - "defaultMessage": "Registrarte" + "defaultMessage": "Registrarse" }, "drawer_menu.link.site_map": { "defaultMessage": "Mapa del sitio" @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "Menú" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "Abre un cuadro de diálogo" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "Mi cuenta" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "Mi carrito, número de artículos: {numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "Localizador de tiendas" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "Lista de deseos" }, @@ -691,6 +742,9 @@ "item_attributes.label.quantity": { "defaultMessage": "Cantidad: {quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "Opciones seleccionadas:" + }, "item_image.label.sale": { "defaultMessage": "Ofertas", "description": "A sale badge placed on top of a product image" @@ -699,8 +753,11 @@ "defaultMessage": "No disponible", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "Comienza en" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "Cantidad {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "Selector de cantidad para {productName}. La cantidad seleccionada es {quantity}" }, "lCPCxk": { "defaultMessage": "Seleccione todas las opciones anteriores" @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "Eliminar {product} de la lista de deseos" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "Comienza en {price}" + "product_tile.badge.label.new": { + "defaultMessage": "Crear" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "Ofertas" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "Agregar paquete al carrito" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "Añadir paquete a la lista de deseos" }, "product_view.button.add_set_to_cart": { "defaultMessage": "Agregar conjunto al carrito" @@ -1082,10 +1148,10 @@ "defaultMessage": "Actualización" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "Cantidad de decremento" + "defaultMessage": "Disminuir la cantidad de {productName}" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "Incrementar cantidad" + "defaultMessage": "Incrementar cantidad de {productName}" }, "product_view.label.quantity": { "defaultMessage": "Cantidad" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "Comienza en" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1196,6 +1259,15 @@ "shipping_address.button.continue_to_shipping": { "defaultMessage": "Continuar a método de envío" }, + "shipping_address.label.edit_button": { + "defaultMessage": "Editar {address}" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "Eliminar {address}" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "Formulario de dirección de envío" + }, "shipping_address.title.shipping_address": { "defaultMessage": "Dirección de envío" }, @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "¿Está seguro de que desea cerrar sesión? Deberá volver a registrarse para continuar con su pedido actual." }, + "store_locator.action.find": { + "defaultMessage": "Encontrar" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "Seleccionar un país..." + }, + "store_locator.action.use_my_location": { + "defaultMessage": "Usar mi ubicación" + }, + "store_locator.action.viewMore": { + "defaultMessage": "Ver más" + }, + "store_locator.description.away": { + "defaultMessage": "de distancia" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "Lugares de carga..." + }, + "store_locator.description.no_locations": { + "defaultMessage": "Lo sentimos, no hay ubicaciones en esta área" + }, + "store_locator.description.or": { + "defaultMessage": "O" + }, + "store_locator.description.phone": { + "defaultMessage": "Teléfono:" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "Visualización de tiendas dentro {distance}{distanceUnit} de {postalCode} en" + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "Ver tiendas cerca de tu ubicación" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "Alemania" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "Estados Unidos" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "Acepte compartir su ubicación" + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "Introduzca un código postal." + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "Seleccione un país." + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "Ingrese el código postal" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "Cargar más" + }, + "store_locator.title": { + "defaultMessage": "Buscar una tienda" + }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, "toggle_card.action.edit": { "defaultMessage": "Editar" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "Editar información de contacto" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "Editar información de pago" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "Editar dirección de envío" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "Editar opciones de envío" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "¿Olvidó la contraseña?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "Ingrese su número de teléfono." }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "Ingrese su código postal." + "defaultMessage": "Ingrese su código postal.", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "Ingrese su dirección." @@ -1272,7 +1414,8 @@ "defaultMessage": "Seleccione su país." }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "Seleccione su estado/provincia." + "defaultMessage": "Seleccione su estado.", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "Obligatorio" @@ -1373,9 +1516,15 @@ "use_product.message.inventory_remaining": { "defaultMessage": "¡Solo quedan {stockLevel}!" }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "¡Solo {stockLevel} queda para {productName}!" + }, "use_product.message.out_of_stock": { "defaultMessage": "Agotado" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "Agotado para {productName}" + }, "use_profile_fields.error.required_email": { "defaultMessage": "Introduzca una dirección de correo electrónico válida." }, @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "Contraseña nueva" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "Agregar conjunto de {productName} al carrito" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "Agregar {productName} al carrito" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "Agregar conjunto al carrito" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "Agregar al carrito" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "Ver todos los detalles de {productName}" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "Ver toda la información" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "Ver opciones" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "Ver opciones para {productName}" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one {artículo} other {artículos}} agregado(s) al carrito" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "Eliminar" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "Eliminar {productName}" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "Artículo eliminado de la lista de deseos" }, diff --git a/packages/template-retail-react-app/translations/fr-FR.json b/packages/template-retail-react-app/translations/fr-FR.json index 361367b97f..5a8c2c9493 100644 --- a/packages/template-retail-react-app/translations/fr-FR.json +++ b/packages/template-retail-react-app/translations/fr-FR.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "Article supprimé du panier" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "Modifier la fenêtre modale pour {productName}" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "Vous aimerez peut-être aussi" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "Panier ({itemCount, plural, =0 {0 article} one {# article} other {# articles}})" }, + "category_links.button_text": { + "defaultMessage": "Catégories" + }, "cc_radio_group.action.remove": { "defaultMessage": "Supprimer" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "Livraison" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "À l’origine {originalPrice}, aujourd’hui {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "Sous-total" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "Carte de crédit" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "Formulaire d’adresse de facturation" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "Identique à l’adresse de livraison" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "Oui" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "Non, annuler l’action" + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "Oui, confirmer l’action" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "Voulez-vous vraiment continuer ?" }, @@ -349,6 +367,15 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "Oui, supprimer l’article" }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "Non, garder l’article" + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "Supprimer les produits non disponibles" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "Oui, supprimer l’article" + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { "defaultMessage": "Certains articles ne sont plus disponibles en ligne et seront supprimés de votre panier." }, @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "Cryptogramme" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "prix actuel {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "À partir du prix actuel {currentPrice}" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "prix d’origine {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "À partir du prix d’origine {listPrice}" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "Du {currentPrice}" + }, "drawer_menu.button.account_details": { "defaultMessage": "Détails du compte" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "Historique des commandes" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "Tiroir de menu" + }, "drawer_menu.link.about_us": { "defaultMessage": "À propos de nous" }, @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "Menu" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "Ouvre une boîte de dialogue" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "Mon compte" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "Mon panier, nombre d’articles : {numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "Localisateur de magasins" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "Liste de souhaits" }, @@ -691,16 +742,22 @@ "item_attributes.label.quantity": { "defaultMessage": "Quantité : {quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "Options sélectionnées" + }, "item_image.label.sale": { - "defaultMessage": "Vente", + "defaultMessage": "En solde", "description": "A sale badge placed on top of a product image" }, "item_image.label.unavailable": { "defaultMessage": "Non disponible", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "À partir de" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "Quantité {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "Sélecteur de quantité pour {productName}. La quantité sélectionnée est {quantity}" }, "lCPCxk": { "defaultMessage": "Sélectionnez toutes vos options ci-dessus" @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "Supprimer {product} de la liste de souhaits" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "À partir de {price}" + "product_tile.badge.label.new": { + "defaultMessage": "Nouveau" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "En solde" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "Ajouter l’offre groupée au panier" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "Ajouter l’offre groupée à la liste de souhaits" }, "product_view.button.add_set_to_cart": { "defaultMessage": "Ajouter le lot au panier" @@ -1082,10 +1148,10 @@ "defaultMessage": "Mettre à jour" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "Décrémenter la quantité" + "defaultMessage": "Décrémenter la quantité pour {productName}" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "Incrémenter la quantité" + "defaultMessage": "Incrémenter la quantité pour {productName}" }, "product_view.label.quantity": { "defaultMessage": "Quantité" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "À partir de" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1196,6 +1259,15 @@ "shipping_address.button.continue_to_shipping": { "defaultMessage": "Continuer vers le mode de livraison" }, + "shipping_address.label.edit_button": { + "defaultMessage": "Modifier {address}" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "Supprimer {address}" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "Formulaire d’adresse de livraison" + }, "shipping_address.title.shipping_address": { "defaultMessage": "Adresse de livraison" }, @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "Voulez-vous vraiment vous déconnecter ? Vous devrez vous reconnecter pour poursuivre votre commande en cours." }, + "store_locator.action.find": { + "defaultMessage": "Rechercher" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "Sélectionner un pays" + }, + "store_locator.action.use_my_location": { + "defaultMessage": "Utiliser mon emplacement" + }, + "store_locator.action.viewMore": { + "defaultMessage": "Afficher plus" + }, + "store_locator.description.away": { + "defaultMessage": "à" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "Lieux de chargement..." + }, + "store_locator.description.no_locations": { + "defaultMessage": "Désolé, il n’y a pas d’emplacements dans cette zone" + }, + "store_locator.description.or": { + "defaultMessage": "Ou" + }, + "store_locator.description.phone": { + "defaultMessage": "Téléphone :" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "Affichage des magasins à moins de {distance} {distanceUnit} de {postalCode} dans ce pays :" + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "Affichage des magasins à proximité de votre emplacement" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "Allemagne" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "États-Unis" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "Veuillez accepter de partager votre emplacement" + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "Veuillez saisir un code postal." + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "Veuillez sélectionner un pays." + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "Entrer un code postal" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "Charger plus de résultats" + }, + "store_locator.title": { + "defaultMessage": "Trouver un magasin" + }, "swatch_group.selected.label": { "defaultMessage": "{label} :" }, "toggle_card.action.edit": { "defaultMessage": "Modifier" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "Modifier les coordonnées" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "Modifier les informations de paiement" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "Modifier l’adresse de livraison" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "Modifier les options de livraison" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "Mot de passe oublié ?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "Veuillez indiquer votre numéro de téléphone." }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "Veuillez indiquer votre code postal." + "defaultMessage": "Veuillez indiquer votre code postal.", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "Veuillez indiquer votre adresse." @@ -1272,7 +1414,8 @@ "defaultMessage": "Veuillez sélectionner votre pays." }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "Veuillez sélectionner votre État/province." + "defaultMessage": "Veuillez sélectionner votre État/province.", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "Obligatoire" @@ -1373,9 +1516,15 @@ "use_product.message.inventory_remaining": { "defaultMessage": "Il n’en reste plus que {stockLevel} !" }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "Il ne reste plus que {stockLevel} articles pour {productName} !" + }, "use_product.message.out_of_stock": { "defaultMessage": "En rupture de stock" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "Rupture de stock pour {productName}" + }, "use_profile_fields.error.required_email": { "defaultMessage": "Saisissez une adresse e-mail valide." }, @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "Nouveau mot de passe" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "Ajouter le lot {productName} au panier" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "Ajouter le {productName} au panier" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "Ajouter le lot au panier" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "Ajouter au panier" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "Afficher tous les détails pour {productName}" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "Afficher tous les détails" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "Afficher les options" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "Afficher les options pour {productName}" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one {article ajouté} other {articles ajoutés}} au panier" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "Supprimer" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "Supprimer {productName}" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "Article supprimé de la liste de souhaits" }, diff --git a/packages/template-retail-react-app/translations/it-IT.json b/packages/template-retail-react-app/translations/it-IT.json index 2123617bcf..f7a419a2bd 100644 --- a/packages/template-retail-react-app/translations/it-IT.json +++ b/packages/template-retail-react-app/translations/it-IT.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "Articolo rimosso dal carrello" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "Modifica modale per {productName}" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "Potrebbe interessarti anche" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "Carrello ({itemCount, plural, =0 {0 articoli} one {# articolo} other {# articoli}})" }, + "category_links.button_text": { + "defaultMessage": "Categorie" + }, "cc_radio_group.action.remove": { "defaultMessage": "Rimuovi" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "Spedizione" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "Originariamente {originalPrice}, ora {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "Subtotale" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "Carta di credito" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "Modulo indirizzo di fatturazione" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "Identico all'indirizzo di spedizione" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "Sì" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "No, annulla azione" + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "Sì, conferma azione" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "Continuare?" }, @@ -349,8 +367,17 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "Sì, rimuovi articolo" }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "No, conserva articolo" + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "Rimuovi prodotti non disponibili" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "Sì, rimuovi articolo" + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { - "defaultMessage": "Alcuni articoli non sono più dispoinibili online e verranno rimossi dal carrello." + "defaultMessage": "Alcuni articoli non sono più disponibili online e verranno rimossi dal carrello." }, "confirmation_modal.remove_cart_item.message.sure_to_remove": { "defaultMessage": "Rimuovere questo articolo dal carrello?" @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "Info codice di sicurezza" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "prezzo attuale {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "A partire dal prezzo attuale {currentPrice}" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "prezzo originale {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "A partire dal prezzo originale {listPrice}" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "Da {currentPrice}" + }, "drawer_menu.button.account_details": { "defaultMessage": "Dettagli account" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "Cronologia ordini" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "Cassetto menu" + }, "drawer_menu.link.about_us": { "defaultMessage": "Chi siamo" }, @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "Menu" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "Apre una finestra di dialogo" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "Il mio account" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "Il mio carrello, numero di articoli: {numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "Store locator" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "Lista desideri" }, @@ -691,6 +742,9 @@ "item_attributes.label.quantity": { "defaultMessage": "Quantità: {quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "Opzioni selezionate" + }, "item_image.label.sale": { "defaultMessage": "Saldi", "description": "A sale badge placed on top of a product image" @@ -699,8 +753,11 @@ "defaultMessage": "Non disponibile", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "A partire da" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "Quantità {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "Selettore di quantità per {productName}. La quantità selezionata è {quantity}" }, "lCPCxk": { "defaultMessage": "Selezionare tutte le opzioni sopra riportate" @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "Rimuovi {product} dalla lista desideri" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "A partire da {price}" + "product_tile.badge.label.new": { + "defaultMessage": "Crea" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "Saldi" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "Aggiungi bundle al carrello" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "Aggiungi Bundle alla Wishlist" }, "product_view.button.add_set_to_cart": { "defaultMessage": "Aggiungi set al carrello" @@ -1082,10 +1148,10 @@ "defaultMessage": "Aggiorna" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "Riduci quantità" + "defaultMessage": "Riduci quantità per {productName}" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "Incrementa quantità" + "defaultMessage": "Aumenta quantità per {productName}" }, "product_view.label.quantity": { "defaultMessage": "Quantità" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "A partire da" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1196,6 +1259,15 @@ "shipping_address.button.continue_to_shipping": { "defaultMessage": "Passa al metodo di spedizione" }, + "shipping_address.label.edit_button": { + "defaultMessage": "Modifica {address}" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "Rimuovi {address}" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "Modulo indirizzo di spedizione" + }, "shipping_address.title.shipping_address": { "defaultMessage": "Indirizzo di spedizione" }, @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "Uscire? Per procedere con l'ordine corrente devi eseguire di nuovo l'accesso." }, + "store_locator.action.find": { + "defaultMessage": "Trova" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "Seleziona un Paese" + }, + "store_locator.action.use_my_location": { + "defaultMessage": "Usa la mia posizione" + }, + "store_locator.action.viewMore": { + "defaultMessage": "Visualizza altri" + }, + "store_locator.description.away": { + "defaultMessage": "di distanza" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "Caricamento posizioni..." + }, + "store_locator.description.no_locations": { + "defaultMessage": "Siamo spiacenti, non ci sono sedi in quest'area" + }, + "store_locator.description.or": { + "defaultMessage": "Oppure" + }, + "store_locator.description.phone": { + "defaultMessage": "Telefono:" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "Visualizzazione dei negozi entro {distance} {distanceUnit} da {postalCode} in:" + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "Visualizzazione dei negozi vicino alla tua posizione" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "Germania" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "Stati Uniti" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "Accetta di condividere la tua posizione" + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "Inserisci un codice postale." + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "Seleziona un Paese." + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "Inserisci codice postale" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "Carica altri" + }, + "store_locator.title": { + "defaultMessage": "Trova un negozio" + }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, "toggle_card.action.edit": { "defaultMessage": "Modifica" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "Modifica informazioni di contatto" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "Modifica informazioni di pagamento" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "Modifica indirizzo di spedizione" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "Modifica opzioni di spedizione" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "Password dimenticata?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "Inserisci il numero di telefono." }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "Inserisci il codice postale." + "defaultMessage": "Inserisci il tuo codice postale.", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "Inserisci l'indirizzo." @@ -1272,7 +1414,8 @@ "defaultMessage": "Seleziona il Paese." }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "Seleziona lo stato/la provincia." + "defaultMessage": "Seleziona il tuo stato.", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "Obbligatorio" @@ -1373,9 +1516,15 @@ "use_product.message.inventory_remaining": { "defaultMessage": "Solo {stockLevel} rimasti!" }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "Solo {stockLevel} rimasti per {productName}!" + }, "use_product.message.out_of_stock": { "defaultMessage": "Esaurito" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "Esaurito per {productName}" + }, "use_profile_fields.error.required_email": { "defaultMessage": "Inserisci un indirizzo e-mail valido." }, @@ -1434,7 +1583,7 @@ "defaultMessage": "Inserisci il cognome." }, "use_registration_fields.error.required_password": { - "defaultMessage": "Creare una password." + "defaultMessage": "Crea una password." }, "use_registration_fields.error.special_character": { "defaultMessage": "La password deve contenere almeno un carattere speciale." @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "Nuova password" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "Aggiungi set {productName} al carrello" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "Aggiungi {productName} al carrello" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "Aggiungi set al carrello" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "Aggiungi al carrello" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "Mostra tutti i dettagli per {productName}" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "Mostra tutti i dettagli" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "Visualizza opzioni" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "Visualizza opzioni per {productName}" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one {articolo aggiunto} other {articoli aggiunti}} al carrello" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "Rimuovi" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "Rimuovi {productName}" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "Articolo rimosso dalla lista desideri" }, diff --git a/packages/template-retail-react-app/translations/ja-JP.json b/packages/template-retail-react-app/translations/ja-JP.json index fe206d8b7e..894fe592bb 100644 --- a/packages/template-retail-react-app/translations/ja-JP.json +++ b/packages/template-retail-react-app/translations/ja-JP.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "買い物カゴから商品が削除されました" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "{productName} のモーダルを編集" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "こちらもおすすめ" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "買い物カゴ ({itemCount, plural, =0 {0 個の商品} one {# 個の商品} other {# 個の商品}})" }, + "category_links.button_text": { + "defaultMessage": "カテゴリ" + }, "cc_radio_group.action.remove": { "defaultMessage": "削除" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "配送" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "元の価格は {originalPrice} だが、現在は {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "小計" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "クレジットカード" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "請求先住所フォーム" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "配送先住所と同じ" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "はい" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "いいえ、操作をキャンセルします" + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "はい、操作を確認します" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "続行しますか?" }, @@ -349,6 +367,15 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "はい、商品を削除します" }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "いいえ、商品をキープします" + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "入手不可の商品を削除" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "はい、商品を削除します" + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { "defaultMessage": "一部の商品がオンラインで入手できなくなったため、買い物カゴから削除されます。" }, @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "セキュリティコード情報" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "現在の価格 {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "現在の価格 {currentPrice} から" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "元の価格 {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "元の価格 {listPrice} から" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "{currentPrice} から" + }, "drawer_menu.button.account_details": { "defaultMessage": "アカウントの詳細" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "注文履歴" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "ドロワーメニュー" + }, "drawer_menu.link.about_us": { "defaultMessage": "企業情報" }, @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "メニュー" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "ダイアログを開く" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "マイアカウント" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "マイ買い物カゴ、商品数: {numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "店舗検索" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "ほしい物リスト" }, @@ -691,6 +742,9 @@ "item_attributes.label.quantity": { "defaultMessage": "数量: {quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "選択したオプション" + }, "item_image.label.sale": { "defaultMessage": "セール", "description": "A sale badge placed on top of a product image" @@ -699,8 +753,11 @@ "defaultMessage": "入手不可", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "最低価格" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "数量 {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "{productName}の数量セレクター。選択された数量は {quantity} です" }, "lCPCxk": { "defaultMessage": "上記のすべてのオプションを選択してください" @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "{product} をほしい物リストから削除" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "最低価格: {price}" + "product_tile.badge.label.new": { + "defaultMessage": "新規" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "セール" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "バンドルを買い物カゴに追加" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "バンドルをほしい物リストに追加" }, "product_view.button.add_set_to_cart": { "defaultMessage": "セットを買い物カゴに追加" @@ -1082,10 +1148,10 @@ "defaultMessage": "更新" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "数量を減らす" + "defaultMessage": "{productName} の数量を減らす" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "数量を増やす" + "defaultMessage": "{productName} の数量を増やす" }, "product_view.label.quantity": { "defaultMessage": "数量" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "最低価格" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1151,7 +1214,7 @@ "defaultMessage": "さあ、始めましょう!" }, "register_form.message.agree_to_policy_terms": { - "defaultMessage": "アカウントを作成した場合、Salesforce のプライバシーポリシー使用条件にご同意いただいたものと見なされます" + "defaultMessage": "アカウントを作成した場合、Salesforce のプライバシーポリシー使用条件にご同意いただいたものと見なされます。" }, "register_form.message.already_have_account": { "defaultMessage": "すでにアカウントをお持ちですか?" @@ -1196,6 +1259,15 @@ "shipping_address.button.continue_to_shipping": { "defaultMessage": "配送方法に進む" }, + "shipping_address.label.edit_button": { + "defaultMessage": "{address} の編集" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "{address} の削除" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "配送先住所フォーム" + }, "shipping_address.title.shipping_address": { "defaultMessage": "配送先住所" }, @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "サインアウトしますか?現在のご注文を処理するには、再度サインインする必要があります。" }, + "store_locator.action.find": { + "defaultMessage": "検索" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "国を選択してください" + }, + "store_locator.action.use_my_location": { + "defaultMessage": "現在地を使用" + }, + "store_locator.action.viewMore": { + "defaultMessage": "もっと見る" + }, + "store_locator.description.away": { + "defaultMessage": "の距離" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "位置情報を読み込んでいます..." + }, + "store_locator.description.no_locations": { + "defaultMessage": "申し訳ございませんが、このエリアには店舗がありません" + }, + "store_locator.description.or": { + "defaultMessage": "または" + }, + "store_locator.description.phone": { + "defaultMessage": "電話:" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "次の {postalCode} から {distance}{distanceUnit} 以内の店舗を表示しています: " + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "現在地の近くの店舗を表示しています" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "ドイツ" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "米国" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "現在地を共有することに同意してください" + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "郵便番号を入力してください。" + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "国を選択してください。" + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "郵便番号を入力してください" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "さらに読み込む" + }, + "store_locator.title": { + "defaultMessage": "店舗の検索" + }, "swatch_group.selected.label": { "defaultMessage": "{label}: " }, "toggle_card.action.edit": { "defaultMessage": "編集" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "連絡先情報の編集" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "支払情報の編集" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "配送先住所の編集" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "配送オプションの編集" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "パスワードを忘れましたか?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "電話番号を入力してください。" }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "郵便番号を入力してください。" + "defaultMessage": "郵便番号を入力してください。", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "住所を入力してください。" @@ -1272,7 +1414,8 @@ "defaultMessage": "国を選択してください。" }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "州を選択してください。" + "defaultMessage": "州を選択してください。", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "必須" @@ -1371,11 +1514,17 @@ "defaultMessage": "パスワード" }, "use_product.message.inventory_remaining": { - "defaultMessage": "残り {stockLevel} 点!" + "defaultMessage": "残り {stockLevel} 点のみ!" + }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "{productName} は残り {stockLevel} 点のみ!" }, "use_product.message.out_of_stock": { "defaultMessage": "在庫切れ" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "{productName} は在庫切れです" + }, "use_profile_fields.error.required_email": { "defaultMessage": "有効な Eメールアドレスを入力してください。" }, @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "新しいパスワード:" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "{productName} のセットを買い物カゴに追加" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "{productName} を買い物カゴに追加" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "セットを買い物カゴに追加" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "買い物カゴに追加" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "{productName} の詳細を表示" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "すべての情報を表示" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "オプションを表示" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "{productName} のオプションを表示" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one { 個の商品} other { 個の商品}}が買い物カゴに追加されました" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "削除" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "{productName} の削除" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "ほしい物リストから商品が削除されました" }, diff --git a/packages/template-retail-react-app/translations/ko-KR.json b/packages/template-retail-react-app/translations/ko-KR.json index 65edc6a05d..26513f6f20 100644 --- a/packages/template-retail-react-app/translations/ko-KR.json +++ b/packages/template-retail-react-app/translations/ko-KR.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "항목이 카트에서 제거됨" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "{productName}에 대한 모달 편집" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "추천 상품" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "카트({itemCount, plural, =0 {0개 항목} one {#개 항목} other {#개 항목}})" }, + "category_links.button_text": { + "defaultMessage": "카테고리" + }, "cc_radio_group.action.remove": { "defaultMessage": "제거" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "배송" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "원래 가격: {originalPrice} , 현재 가격: {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "소계" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "신용카드" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "청구 주소 양식" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "배송 주소와 동일" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "예" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "아니요, 작업을 취소합니다." + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "예, 작업을 확인합니다" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "계속하시겠습니까?" }, @@ -349,6 +367,15 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "예. 항목을 제거합니다." }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "아니요. 항목을 그대로 둡니다." + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "사용할 수 없는 제품 제거" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "예. 항목을 제거합니다." + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { "defaultMessage": "더 이상 온라인으로 구매할 수 없는 일부 품목이 카트에서 제거됩니다." }, @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "보안 코드 정보" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "현재 가격 {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "현재 가격 {currentPrice}에서" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "원래 가격 {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "원래 가격 {listPrice}에서" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "{currentPrice}부터 시작" + }, "drawer_menu.button.account_details": { "defaultMessage": "계정 세부 정보" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "주문 내역" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "메뉴 서랍" + }, "drawer_menu.link.about_us": { "defaultMessage": "회사 정보" }, @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "메뉴" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "대화창 열기" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "내 계정" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "내 카트, 품목 수: {numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "매장 찾기" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "위시리스트" }, @@ -691,6 +742,9 @@ "item_attributes.label.quantity": { "defaultMessage": "수량: {quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "선택한 옵션" + }, "item_image.label.sale": { "defaultMessage": "판매", "description": "A sale badge placed on top of a product image" @@ -699,8 +753,11 @@ "defaultMessage": "사용 불가", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "시작가" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "수량 {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "{productName}에 대한 수량 선택기 선택한 수량은 {quantity}개입니다." }, "lCPCxk": { "defaultMessage": "위에서 옵션을 모두 선택하세요." @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "위시리스트에서 {product} 제거" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "시작가: {price}" + "product_tile.badge.label.new": { + "defaultMessage": "신규" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "판매" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "카트에 번들 추가" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "위시리스트에 번들 추가" }, "product_view.button.add_set_to_cart": { "defaultMessage": "카트에 세트 추가" @@ -1082,10 +1148,10 @@ "defaultMessage": "업데이트" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "수량 줄이기" + "defaultMessage": "{productName}의 감소 수량" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "수량 늘리기" + "defaultMessage": "{productName}에 대한 증분 수량" }, "product_view.label.quantity": { "defaultMessage": "수량" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "시작가" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1151,7 +1214,7 @@ "defaultMessage": "이제 시작하세요!" }, "register_form.message.agree_to_policy_terms": { - "defaultMessage": "계정을 만들면 Salesforce 개인정보보호 정책이용 약관에 동의한 것으로 간주됩니다." + "defaultMessage": "계정을 만들면 Salesforce 개인정보 보호정책약관에 동의하는 것입니다." }, "register_form.message.already_have_account": { "defaultMessage": "계정이 이미 있습니까?" @@ -1196,6 +1259,15 @@ "shipping_address.button.continue_to_shipping": { "defaultMessage": "배송 방법으로 계속 진행하기" }, + "shipping_address.label.edit_button": { + "defaultMessage": "{address} 편집" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "{address} 제거" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "배송 주소 양식" + }, "shipping_address.title.shipping_address": { "defaultMessage": "배송 주소" }, @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "로그아웃하시겠습니까? 현재 주문을 처리하려면 다시 로그인해야 합니다." }, + "store_locator.action.find": { + "defaultMessage": "찾기" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "국가 선택" + }, + "store_locator.action.use_my_location": { + "defaultMessage": "내 위치 사용" + }, + "store_locator.action.viewMore": { + "defaultMessage": "자세히 보기" + }, + "store_locator.description.away": { + "defaultMessage": "떨어진 곳에 위치" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "위치 로드 중..." + }, + "store_locator.description.no_locations": { + "defaultMessage": "죄송하지만 이 지역에는 위치가 없습니다." + }, + "store_locator.description.or": { + "defaultMessage": "Or" + }, + "store_locator.description.phone": { + "defaultMessage": "전화번호:" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "{postalCode}에서 {distance}{distanceUnit} 내에 위치한 매장 보기" + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "현재 위치에서 가까운 매장 보기" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "독일" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "미국" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "위치 공유에 동의하십시오." + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "우편번호를 입력해 주세요." + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "국가를 선택하십시오." + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "우편번호 입력" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "추가 로드" + }, + "store_locator.title": { + "defaultMessage": "매장 찾기" + }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, "toggle_card.action.edit": { "defaultMessage": "편집" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "연락처 정보 편집" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "결제 정보 편집" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "배송 주소 편집" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "배송 옵션 편집" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "암호가 기억나지 않습니까?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "전화번호를 입력하십시오." }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "우편번호를 입력하십시오." + "defaultMessage": "우편번호를 입력하십시오.", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "주소를 입력하십시오." @@ -1272,7 +1414,8 @@ "defaultMessage": "국가를 선택하십시오." }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "시/도를 선택하십시오." + "defaultMessage": "주를 선택하십시오.", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "필수" @@ -1373,9 +1516,15 @@ "use_product.message.inventory_remaining": { "defaultMessage": "품절 임박({stockLevel}개 남음)" }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "{productName}이(가) {stockLevel}개 남았습니다!" + }, "use_product.message.out_of_stock": { "defaultMessage": "품절" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "{productName}이(가) 품절입니다." + }, "use_profile_fields.error.required_email": { "defaultMessage": "유효한 이메일 주소를 입력하십시오." }, @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "새 암호" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "카트에 {productName} 세트 추가" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "카트에 {productName} 추가" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "카트에 세트 추가" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "카트에 추가" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "{productName}에 대한 전체 세부 정보 보기" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "전체 세부 정보 보기" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "옵션 보기" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "{productName}에 대한 보기 옵션" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one {개 항목} other {개 항목}}이 카트에 추가됨" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "제거" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "{productName} 제거" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "항목이 위시리스트에서 제거됨" }, diff --git a/packages/template-retail-react-app/translations/pt-BR.json b/packages/template-retail-react-app/translations/pt-BR.json index ea6935042b..9c5596a015 100644 --- a/packages/template-retail-react-app/translations/pt-BR.json +++ b/packages/template-retail-react-app/translations/pt-BR.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "Item removido do carrinho" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "Editar modal para {productName}" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "Talvez você também queira" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "Carrinho ({itemCount, plural, =0 {0 itens} one {# item} other {# itens}})" }, + "category_links.button_text": { + "defaultMessage": "Categorias" + }, "cc_radio_group.action.remove": { "defaultMessage": "Remover" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "Frete" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "Originalmente {originalPrice}, agora {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "Subtotal" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "Cartão de crédito" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "Formulário de endereço para faturamento" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "Igual ao endereço de entrega" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "Sim" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "Não, cancelar ação" + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "Sim, confirmar ação" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "Tem certeza de que deseja continuar?" }, @@ -349,6 +367,15 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "Sim, remover item" }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "Não, manter item" + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "Remover produtos indisponíveis" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "Sim, remover item" + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { "defaultMessage": "Alguns itens não estão mais disponíveis online e serão removidos de seu carrinho." }, @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "Informações do código de segurança" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "preço atual {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "A partir do preço atual {currentPrice}" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "preço original {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "A partir do preço original {listPrice}" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "De {currentPrice}" + }, "drawer_menu.button.account_details": { "defaultMessage": "Detalhes da conta" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "Histórico de pedidos" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "Gaveta de menu" + }, "drawer_menu.link.about_us": { "defaultMessage": "Sobre nós" }, @@ -427,7 +472,7 @@ "defaultMessage": "Suporte ao cliente" }, "drawer_menu.link.customer_support.contact_us": { - "defaultMessage": "Entrar em contato" + "defaultMessage": "Entre em contato" }, "drawer_menu.link.customer_support.shipping_and_returns": { "defaultMessage": "Frete e devoluções" @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "Menu" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "Abre uma caixa de diálogo" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "Minha conta" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "Meu carrinho, número de itens: {numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "Localizador de lojas" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "Lista de desejos" }, @@ -691,6 +742,9 @@ "item_attributes.label.quantity": { "defaultMessage": "Quantidade: {quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "Opções selecionadas" + }, "item_image.label.sale": { "defaultMessage": "Promoção", "description": "A sale badge placed on top of a product image" @@ -699,8 +753,11 @@ "defaultMessage": "Indisponível", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "A partir de" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "Quantidade {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "Seletor de quantidade para {productName}. A quantidade selecionada é {quantity}" }, "lCPCxk": { "defaultMessage": "Selecione todas as opções acima" @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "Remover {product} da lista de desejos" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "A partir de {price}" + "product_tile.badge.label.new": { + "defaultMessage": "Criar" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "Promoção" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "Adicionar pacote ao carrinho" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "Adicionar pacote à lista de desejos" }, "product_view.button.add_set_to_cart": { "defaultMessage": "Adicionar conjunto ao carrinho" @@ -1082,10 +1148,10 @@ "defaultMessage": "Atualizar" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "Quantidade de decremento" + "defaultMessage": "Quantidade em decremento para {productName}" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "Quantidade de incremento" + "defaultMessage": "Quantidade em incremento para {productName}" }, "product_view.label.quantity": { "defaultMessage": "Quantidade" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "A partir de" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1196,6 +1259,15 @@ "shipping_address.button.continue_to_shipping": { "defaultMessage": "Ir ao método de entrega" }, + "shipping_address.label.edit_button": { + "defaultMessage": "Editar {address}" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "Remover {address}" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "Formulário de endereço de entrega" + }, "shipping_address.title.shipping_address": { "defaultMessage": "Endereço de entrega" }, @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "Tem certeza de que deseja fazer logout? Será preciso fazer logon novamente para dar continuidade ao seu pedido atual." }, + "store_locator.action.find": { + "defaultMessage": "Localizar" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "Selecione um país" + }, + "store_locator.action.use_my_location": { + "defaultMessage": "Utilizar a minha localização" + }, + "store_locator.action.viewMore": { + "defaultMessage": "Ver mais" + }, + "store_locator.description.away": { + "defaultMessage": "de distância" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "Carregando localizações..." + }, + "store_locator.description.no_locations": { + "defaultMessage": "Desculpe, não há localizações nesta área" + }, + "store_locator.description.or": { + "defaultMessage": "Ou" + }, + "store_locator.description.phone": { + "defaultMessage": "Telefone:" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "Visualizando lojas dentro de {distance}{distanceUnit} de {postalCode} em" + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "Ver lojas perto da sua localização" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "Alemanha" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "Estados Unidos" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "Aceite compartilhar sua localização" + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "Insira um código postal." + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "Selecione um país." + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "Inserir código postal" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "Carregar mais" + }, + "store_locator.title": { + "defaultMessage": "Encontre uma loja" + }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, "toggle_card.action.edit": { "defaultMessage": "Editar" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "Editar informações de contato" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "Editar informações de pagamento" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "Editar endereço de entrega" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "Editar opções de envio" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "Esqueceu a senha?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "Insira seu telefone." }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "Insira seu código postal." + "defaultMessage": "Insira seu CEP.", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "Insira seu endereço." @@ -1272,7 +1414,8 @@ "defaultMessage": "Selecione o país." }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "Selecione estado/província." + "defaultMessage": "Selecione seu estado.", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "Requerido" @@ -1373,9 +1516,15 @@ "use_product.message.inventory_remaining": { "defaultMessage": "Somente {stockLevel} restante(s)!" }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "Sobraram somente {stockLevel} para {productName}!" + }, "use_product.message.out_of_stock": { "defaultMessage": "Fora de estoque" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "{productName} esgotado(a)" + }, "use_profile_fields.error.required_email": { "defaultMessage": "Insira um endereço de e-mail válido." }, @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "Nova senha" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "Adicionar conjunto de {productName} ao carrinho" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "Adicionar {productName} ao carrinho" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "Adicionar conjunto ao carrinho" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "Adicionar ao carrinho" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "Ver todos os detalhes de {productName}" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "Ver detalhes completos" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "Ver opções" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "Ver opções para {productName}" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one {item} other {itens}} adicionado(s) ao carrinho" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "Remover" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "Remover {productName}" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "Item removido da lista de desejos" }, diff --git a/packages/template-retail-react-app/translations/zh-CN.json b/packages/template-retail-react-app/translations/zh-CN.json index dbd4f6d9d8..eccabe279b 100644 --- a/packages/template-retail-react-app/translations/zh-CN.json +++ b/packages/template-retail-react-app/translations/zh-CN.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "从购物车中移除商品" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "编辑 {productName} 模态" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "您可能还喜欢" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "购物车({itemCount, plural, =0 {0 件商品} one {# 件商品} other {# 件商品}})" }, + "category_links.button_text": { + "defaultMessage": "类别" + }, "cc_radio_group.action.remove": { "defaultMessage": "移除" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "送货" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "原价 {originalPrice},现价 {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "小计" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "信用卡" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "帐单地址表格" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "与送货地址相同" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "是" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "否,取消操作" + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "是,确认操作" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "是否确定要继续?" }, @@ -349,6 +367,15 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "是,移除商品" }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "否,保留商品" + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "移除无货产品" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "是,移除商品" + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { "defaultMessage": "某些商品不再在线销售,并将从您的购物车中删除。" }, @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "安全码信息" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "当前价格 {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "从当前价格 {currentPrice}" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "原价 {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "从原价 {listPrice}" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "从 {currentPrice} 起" + }, "drawer_menu.button.account_details": { "defaultMessage": "账户详情" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "订单记录" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "菜单抽屉" + }, "drawer_menu.link.about_us": { "defaultMessage": "关于我们" }, @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "菜单" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "打开对话框" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "我的账户" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "我的购物车,商品数量:{numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "实体店地址搜索" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "愿望清单" }, @@ -691,6 +742,9 @@ "item_attributes.label.quantity": { "defaultMessage": "数量:{quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "已选选项" + }, "item_image.label.sale": { "defaultMessage": "销售", "description": "A sale badge placed on top of a product image" @@ -699,8 +753,11 @@ "defaultMessage": "不可用", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "起价:" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "数量 {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "{productName} 的数量选择器。选择的数量是 {quantity}" }, "lCPCxk": { "defaultMessage": "请在上方选择您的所有选项" @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "从愿望清单删除 {product}" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "起价:{price}" + "product_tile.badge.label.new": { + "defaultMessage": "新建" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "销售" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "将套装添加到购物车" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "将套装添加到心愿单" }, "product_view.button.add_set_to_cart": { "defaultMessage": "将套装添加到购物车" @@ -1082,10 +1148,10 @@ "defaultMessage": "更新" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "递减数量" + "defaultMessage": "递减 {productName} 数量" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "递增数量" + "defaultMessage": "递增 {productName} 数量" }, "product_view.label.quantity": { "defaultMessage": "数量" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "起价:" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1151,7 +1214,7 @@ "defaultMessage": "开始使用!" }, "register_form.message.agree_to_policy_terms": { - "defaultMessage": "创建账户即表明您同意 Salesforce 隐私政策以及条款与条件" + "defaultMessage": "创建帐户即表示您同意 Salesforce 隐私政策条款与条件" }, "register_form.message.already_have_account": { "defaultMessage": "已有账户?" @@ -1196,6 +1259,15 @@ "shipping_address.button.continue_to_shipping": { "defaultMessage": "继续并选择送货方式" }, + "shipping_address.label.edit_button": { + "defaultMessage": "编辑 {address}" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "移除{address}" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "送货地址表格" + }, "shipping_address.title.shipping_address": { "defaultMessage": "送货地址" }, @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "是否确定要注销?您需要重新登录才能继续处理当前订单。" }, + "store_locator.action.find": { + "defaultMessage": "查找" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "选择国家/地区" + }, + "store_locator.action.use_my_location": { + "defaultMessage": "使用我的位置" + }, + "store_locator.action.viewMore": { + "defaultMessage": "查看更多" + }, + "store_locator.description.away": { + "defaultMessage": "離開" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "正在加载位置..." + }, + "store_locator.description.no_locations": { + "defaultMessage": "对不起,这个区域没有位置" + }, + "store_locator.description.or": { + "defaultMessage": "或" + }, + "store_locator.description.phone": { + "defaultMessage": "电话:" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "查看查看距离 {postalCode} {distance}{distanceUnit} 内的实体店" + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "查看您所在位置附近的实体店" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "德国" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "美国" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "请同意分享您的所在位置" + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "请输入邮政编码。" + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "请选择国家。" + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "输入邮政编码" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "加载更多" + }, + "store_locator.title": { + "defaultMessage": "查找实体店" + }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, "toggle_card.action.edit": { "defaultMessage": "编辑" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "编辑联系信息" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "编辑付款信息" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "编辑送货地址" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "编辑送货选项" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "忘记密码?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "请输入您的电话号码。" }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "请输入您的邮政编码。" + "defaultMessage": "请输入您的邮政编码。", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "请输入您的地址。" @@ -1272,7 +1414,8 @@ "defaultMessage": "请输入您所在国家/地区。" }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "请选择您所在的州/省。" + "defaultMessage": "请选择您所在的州。", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "必填" @@ -1373,9 +1516,15 @@ "use_product.message.inventory_remaining": { "defaultMessage": "仅剩 {stockLevel} 件!" }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "{productName} 只剩下 {stockLevel}!" + }, "use_product.message.out_of_stock": { "defaultMessage": "无库存" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "{productName} 无库存" + }, "use_profile_fields.error.required_email": { "defaultMessage": "请输入有效的电子邮件地址。" }, @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "新密码" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "将 {productName} 套装添加到购物车" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "将 {productName} 添加到购物车" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "将套装添加到购物车" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "添加到购物车" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "查看 {productName} 的完整详细信息" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "查看完整详情" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "查看选项" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "查看 {productName} 的选项" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one { 件商品} other { 件商品}}已添加至购物车" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "移除" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "移除{productName}" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "从愿望清单中移除商品" }, diff --git a/packages/template-retail-react-app/translations/zh-TW.json b/packages/template-retail-react-app/translations/zh-TW.json index ef358ce253..b58628ccc2 100644 --- a/packages/template-retail-react-app/translations/zh-TW.json +++ b/packages/template-retail-react-app/translations/zh-TW.json @@ -174,6 +174,9 @@ "cart.info.removed_from_cart": { "defaultMessage": "已從購物車移除商品" }, + "cart.product_edit_modal.modal_label": { + "defaultMessage": "{productName} 的編輯互動視窗 (modal)" + }, "cart.recommended_products.title.may_also_like": { "defaultMessage": "您可能也喜歡" }, @@ -204,6 +207,9 @@ "cart_title.title.cart_num_of_items": { "defaultMessage": "購物車 ({itemCount, plural, =0 {0 件商品} one {# 件商品} other {# 件商品}})" }, + "category_links.button_text": { + "defaultMessage": "類別" + }, "cc_radio_group.action.remove": { "defaultMessage": "移除" }, @@ -261,6 +267,9 @@ "checkout_confirmation.label.shipping": { "defaultMessage": "運送" }, + "checkout_confirmation.label.shipping.strikethrough.price": { + "defaultMessage": "原本 {originalPrice} ,現在 {newPrice}" + }, "checkout_confirmation.label.subtotal": { "defaultMessage": "小計" }, @@ -319,6 +328,9 @@ "checkout_payment.heading.credit_card": { "defaultMessage": "信用卡" }, + "checkout_payment.label.billing_address_form": { + "defaultMessage": "帳單地址表單" + }, "checkout_payment.label.same_as_shipping": { "defaultMessage": "與運送地址相同" }, @@ -334,6 +346,12 @@ "confirmation_modal.default.action.yes": { "defaultMessage": "是" }, + "confirmation_modal.default.assistive_msg.no": { + "defaultMessage": "否,取消動作" + }, + "confirmation_modal.default.assistive_msg.yes": { + "defaultMessage": "是,確認動作" + }, "confirmation_modal.default.message.you_want_to_continue": { "defaultMessage": "確定要繼續嗎?" }, @@ -349,6 +367,15 @@ "confirmation_modal.remove_cart_item.action.yes": { "defaultMessage": "是,移除商品" }, + "confirmation_modal.remove_cart_item.assistive_msg.no": { + "defaultMessage": "否,保留商品" + }, + "confirmation_modal.remove_cart_item.assistive_msg.remove": { + "defaultMessage": "移除無法提供的產品" + }, + "confirmation_modal.remove_cart_item.assistive_msg.yes": { + "defaultMessage": "是,移除商品" + }, "confirmation_modal.remove_cart_item.message.need_to_remove_due_to_unavailability": { "defaultMessage": "有些商品已無法再於線上取得,因此將從您的購物車中移除。" }, @@ -405,6 +432,21 @@ "credit_card_fields.tool_tip.security_code_aria_label": { "defaultMessage": "安全碼資訊" }, + "display_price.assistive_msg.current_price": { + "defaultMessage": "目前價格 {currentPrice}" + }, + "display_price.assistive_msg.current_price_with_range": { + "defaultMessage": "從目前價格 {currentPrice}" + }, + "display_price.assistive_msg.strikethrough_price": { + "defaultMessage": "原價 {listPrice}" + }, + "display_price.assistive_msg.strikethrough_price_with_range": { + "defaultMessage": "從原價 {listPrice}" + }, + "display_price.label.current_price_with_range": { + "defaultMessage": "從 {currentPrice}" + }, "drawer_menu.button.account_details": { "defaultMessage": "帳戶詳細資料" }, @@ -420,6 +462,9 @@ "drawer_menu.button.order_history": { "defaultMessage": "訂單記錄" }, + "drawer_menu.header.assistive_msg.title": { + "defaultMessage": "隱藏式側選單" + }, "drawer_menu.link.about_us": { "defaultMessage": "關於我們" }, @@ -582,6 +627,9 @@ "header.button.assistive_msg.menu": { "defaultMessage": "選單" }, + "header.button.assistive_msg.menu.open_dialog": { + "defaultMessage": "開啟對話方塊" + }, "header.button.assistive_msg.my_account": { "defaultMessage": "我的帳戶" }, @@ -591,6 +639,9 @@ "header.button.assistive_msg.my_cart_with_num_items": { "defaultMessage": "我的購物車,商品數量:{numItems}" }, + "header.button.assistive_msg.store_locator": { + "defaultMessage": "商店位置搜尋" + }, "header.button.assistive_msg.wishlist": { "defaultMessage": "願望清單" }, @@ -691,6 +742,9 @@ "item_attributes.label.quantity": { "defaultMessage": "數量:{quantity}" }, + "item_attributes.label.selected_options": { + "defaultMessage": "已選取的選項" + }, "item_image.label.sale": { "defaultMessage": "特價", "description": "A sale badge placed on top of a product image" @@ -699,8 +753,11 @@ "defaultMessage": "不可用", "description": "A unavailable badge placed on top of a product image" }, - "item_price.label.starting_at": { - "defaultMessage": "起始" + "item_variant.assistive_msg.quantity": { + "defaultMessage": "數量 {quantity}" + }, + "item_variant.quantity.label": { + "defaultMessage": "{productName} 的數量選擇器 。 選擇的數量是 {quantity}" }, "lCPCxk": { "defaultMessage": "請在上方選擇所有選項" @@ -1063,8 +1120,17 @@ "product_tile.assistive_msg.remove_from_wishlist": { "defaultMessage": "從願望清單移除 {product}" }, - "product_tile.label.starting_at_price": { - "defaultMessage": "{price} 起" + "product_tile.badge.label.new": { + "defaultMessage": "新增" + }, + "product_tile.badge.label.sale": { + "defaultMessage": "特價" + }, + "product_view.button.add_bundle_to_cart": { + "defaultMessage": "新增搭售方案到購物車" + }, + "product_view.button.add_bundle_to_wishlist": { + "defaultMessage": "新增搭售方案到願望清單" }, "product_view.button.add_set_to_cart": { "defaultMessage": "新增組合至購物車" @@ -1082,10 +1148,10 @@ "defaultMessage": "更新" }, "product_view.label.assistive_msg.quantity_decrement": { - "defaultMessage": "遞減數量" + "defaultMessage": "{productName} 的遞減數量" }, "product_view.label.assistive_msg.quantity_increment": { - "defaultMessage": "遞增數量" + "defaultMessage": "{productName} 的遞增數量" }, "product_view.label.quantity": { "defaultMessage": "數量" @@ -1096,9 +1162,6 @@ "product_view.label.quantity_increment": { "defaultMessage": "+" }, - "product_view.label.starting_at_price": { - "defaultMessage": "起始" - }, "product_view.label.variant_type": { "defaultMessage": "{variantType}" }, @@ -1194,7 +1257,16 @@ "defaultMessage": "全部清除" }, "shipping_address.button.continue_to_shipping": { - "defaultMessage": "繼續前往運送方式" + "defaultMessage": "繼續前往送貨方式" + }, + "shipping_address.label.edit_button": { + "defaultMessage": "編輯 {address}" + }, + "shipping_address.label.remove_button": { + "defaultMessage": "移除 {address}" + }, + "shipping_address.label.shipping_address_form": { + "defaultMessage": "送貨地址表單" }, "shipping_address.title.shipping_address": { "defaultMessage": "運送地址" @@ -1241,12 +1313,81 @@ "signout_confirmation_dialog.message.sure_to_sign_out": { "defaultMessage": "確定要登出嗎?您必須重新登入,才能繼續目前的訂單流程。" }, + "store_locator.action.find": { + "defaultMessage": "尋找" + }, + "store_locator.action.select_a_country": { + "defaultMessage": "選擇國家/地區" + }, + "store_locator.action.use_my_location": { + "defaultMessage": "使用我的位置" + }, + "store_locator.action.viewMore": { + "defaultMessage": "檢視更多" + }, + "store_locator.description.away": { + "defaultMessage": "離開" + }, + "store_locator.description.loading_locations": { + "defaultMessage": "載入位置..." + }, + "store_locator.description.no_locations": { + "defaultMessage": "對不起,此區域沒有位置" + }, + "store_locator.description.or": { + "defaultMessage": "或" + }, + "store_locator.description.phone": { + "defaultMessage": "電話:" + }, + "store_locator.description.viewing_near_postal_code": { + "defaultMessage": "檢視在 {postalCode} 的 {distance} {distanceUnit} 商店" + }, + "store_locator.description.viewing_near_your_location": { + "defaultMessage": "檢視您所在附近的商店位置" + }, + "store_locator.dropdown.germany": { + "defaultMessage": "德國" + }, + "store_locator.dropdown.united_states": { + "defaultMessage": "美國" + }, + "store_locator.error.agree_to_share_your_location": { + "defaultMessage": "請同意分享您的位置" + }, + "store_locator.error.please_enter_a_postal_code": { + "defaultMessage": "請輸入郵遞區號。" + }, + "store_locator.error.please_select_a_country": { + "defaultMessage": "請選擇國家/地區。" + }, + "store_locator.field.placeholder.enter_postal_code": { + "defaultMessage": "輸入郵遞區號" + }, + "store_locator.pagination.load_more": { + "defaultMessage": "載入更多" + }, + "store_locator.title": { + "defaultMessage": "尋找商店" + }, "swatch_group.selected.label": { "defaultMessage": "{label}:" }, "toggle_card.action.edit": { "defaultMessage": "編輯" }, + "toggle_card.action.editContactInfo": { + "defaultMessage": "編輯聯絡資訊" + }, + "toggle_card.action.editPaymentInfo": { + "defaultMessage": "編輯付款資訊" + }, + "toggle_card.action.editShippingAddress": { + "defaultMessage": "編輯運送地址" + }, + "toggle_card.action.editShippingOptions": { + "defaultMessage": "編輯運送選項" + }, "update_password_fields.button.forgot_password": { "defaultMessage": "忘記密碼了嗎?" }, @@ -1260,7 +1401,8 @@ "defaultMessage": "請輸入您的電話號碼。" }, "use_address_fields.error.please_enter_your_postal_or_zip": { - "defaultMessage": "請輸入您的郵遞區號。" + "defaultMessage": "請輸入您的郵遞區號。", + "description": "Error message for a blank zip code (US-specific checkout)" }, "use_address_fields.error.please_select_your_address": { "defaultMessage": "請輸入您的地址。" @@ -1272,7 +1414,8 @@ "defaultMessage": "請選擇您的國家/地區。" }, "use_address_fields.error.please_select_your_state_or_province": { - "defaultMessage": "請選擇您的州/省。" + "defaultMessage": "請選擇您所在的州。", + "description": "Error message for a blank state (US-specific checkout)" }, "use_address_fields.error.required": { "defaultMessage": "必填" @@ -1373,9 +1516,15 @@ "use_product.message.inventory_remaining": { "defaultMessage": "只剩 {stockLevel} 個!" }, + "use_product.message.inventory_remaining_for_product": { + "defaultMessage": "{productName}只剩下 {stockLevel}!" + }, "use_product.message.out_of_stock": { "defaultMessage": "缺貨" }, + "use_product.message.out_of_stock_for_product": { + "defaultMessage": "缺貨 {productName}" + }, "use_profile_fields.error.required_email": { "defaultMessage": "請輸入有效的電子郵件地址。" }, @@ -1490,24 +1639,39 @@ "use_update_password_fields.label.new_password": { "defaultMessage": "新密碼" }, + "wishlist_primary_action.button.addSetToCart.label": { + "defaultMessage": "新增 {productName} 組合至購物車" + }, + "wishlist_primary_action.button.addToCart.label": { + "defaultMessage": "新增 {productName} 至購物車" + }, "wishlist_primary_action.button.add_set_to_cart": { "defaultMessage": "新增組合至購物車" }, "wishlist_primary_action.button.add_to_cart": { "defaultMessage": "新增至購物車" }, + "wishlist_primary_action.button.viewFullDetails.label": { + "defaultMessage": "檢視 {productName} 完整詳細資訊" + }, "wishlist_primary_action.button.view_full_details": { "defaultMessage": "檢視完整詳細資料" }, "wishlist_primary_action.button.view_options": { "defaultMessage": "檢視選項" }, + "wishlist_primary_action.button.view_options.label": { + "defaultMessage": "檢視 {productName} 的選項" + }, "wishlist_primary_action.info.added_to_cart": { "defaultMessage": "{quantity} {quantity, plural, one {件商品} other {件商品}}已新增至購物車" }, "wishlist_secondary_button_group.action.remove": { "defaultMessage": "移除" }, + "wishlist_secondary_button_group.info.item.remove.label": { + "defaultMessage": "移除 {productName}" + }, "wishlist_secondary_button_group.info.item_removed": { "defaultMessage": "已從願望清單移除商品" },