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views/components/buybox-add-to-order-template.tsx?d0da","webpack://illumina-commerce/./src/themes/newsunshine-b2c/views/buybox.view.tsx?7bf0","webpack://illumina-commerce/./src/themes/newsunshine/views/components/buybox-add-to-order-template.tsx?0426","webpack://illumina-commerce/./src/themes/newsunshine/views/buybox.view.tsx?cc62","webpack://illumina-commerce/./lib/buybox/module-registration.js?bcce","webpack://illumina-commerce/./src/store-selector-state-manager/base-store-selector-state-manager.ts?281e","webpack://illumina-commerce/./src/store-selector-state-manager/map-store-selector-state-manager.ts?2ae0","webpack://illumina-commerce/./src/store-selector-state-manager/store-selector-state-manager-data-action.ts?bd3e","webpack://illumina-commerce/./src/modules/fabrikam/views/buybox.view.tsx?aec4","webpack://illumina-commerce/./src/modules/adventureworks/views/components/buybox-add-to-order-template.tsx?ceb4","webpack://illumina-commerce/./src/modules/adventureworks/views/buybox.view.tsx?98cf","webpack://illumina-commerce/external var \"React\"?0d3b","webpack://illumina-commerce/external var \"ReactDOM\"?853b"],"sourcesContent":["/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n */\r\n\r\nimport {\r\n AddToOrderTemplateComponent,\r\n IAddToOrderTemplateDialogResources,\r\n IDuplicateItemsWhenAddingToOrderTemplateDialogResources,\r\n IItemAddedToOrderTemplateDialogResources,\r\n IOrderTemplateActionErrorResult,\r\n IOrderTemplateNameDialogResources\r\n} from '@msdyn365-commerce/components';\r\nimport { SimpleProduct } from '@msdyn365-commerce/retail-proxy';\r\nimport {\r\n getConfigureErrors,\r\n IBuyboxCallbacks,\r\n IBuyboxCommonResources,\r\n IBuyboxData,\r\n IBuyboxState,\r\n IBuyboxViewProps\r\n} from '@msdyn365-commerce-modules/buybox';\r\nimport * as React from 'react';\r\n\r\nimport { IBuyboxProps as IBuyboxExtentionProps } from '../../definition-extensions/buybox.ext.props.autogenerated';\r\n\r\n/**\r\n * To generate AddToOrderTemplateDialog resources.\r\n * @param resources - The resources.\r\n * @returns -- Returns the list of AddToOrderTemplateDialog resources..\r\n */\r\nfunction generateAddToOrderTemplateDialogResources(resources: IBuyboxCommonResources): IAddToOrderTemplateDialogResources {\r\n return {\r\n addToOrderTemplateHeader: resources.addToOrderTemplateHeader,\r\n\r\n noOrderTemplatesMessage: resources.noOrderTemplatesMessage,\r\n noOrderTemplatesDescription: resources.noOrderTemplatesDescription,\r\n\r\n createAnOrderTemplateButtonText: resources.createAnOrderTemplateButtonText,\r\n createNewOrderTemplateButtonText: resources.createNewOrderTemplateButtonText,\r\n cancelOrderTemplateCreationButtonText: resources.cancelOrderTemplateCreationButtonText,\r\n\r\n selectTemplatesText: resources.selectTemplatesText,\r\n addToTemplateButtonText: resources.addToTemplateButtonText,\r\n lineItemsText: resources.lineItemsText\r\n };\r\n}\r\n\r\n/**\r\n * To generate OrderTemplateNameDialog resources.\r\n * @param resources - The resources.\r\n * @returns -- Returns the list of OrderTemplateNameDialog resources..\r\n */\r\nfunction generateOrderTemplateNameDialogResources(resources: IBuyboxCommonResources): IOrderTemplateNameDialogResources {\r\n return {\r\n orderTemplateHeaderLabel: resources.createOrderTemplateHeader,\r\n orderTemplateTitleLabel: resources.orderTemplateTitle,\r\n orderTemplateNameAriaLabel: resources.orderTemplateNameAriaLabel,\r\n orderTemplateDescription: resources.createOrderTemplateDescription,\r\n\r\n defaultOrderTemplateName: resources.defaultOrderTemplateName,\r\n\r\n orderTemplateButtonLabel: resources.createOrderTemplateButtonText,\r\n orderTemplateCancelButtonLabel: resources.cancelNewOrderTemplateCreationButtonText\r\n };\r\n}\r\n\r\n/**\r\n * To generate ItemAddedToOrderTemplateDialog resources.\r\n * @param resources - The resources.\r\n * @returns -- Returns the list of ItemAddedToOrderTemplateDialog resources..\r\n */\r\nfunction generateItemAddedToOrderTemplateDialogResources(resources: IBuyboxCommonResources): IItemAddedToOrderTemplateDialogResources {\r\n return {\r\n viewOrderTemplateButtonText: resources.viewOrderTemplateButtonText,\r\n continueShoppingButtonText: resources.continueShoppingButtonText,\r\n itemAddedToOrderTemplateHeaderItemOneText: resources.itemAddedToOrderTemplateHeaderItemOneText,\r\n itemAddedToOrderTemplateHeaderItemFormatText: resources.itemAddedToOrderTemplateHeaderItemFormatText,\r\n itemAddedToOrderTemplateHeaderMessageText: resources.itemAddedToOrderTemplateHeaderMessageText,\r\n freePriceText: resources.priceFree,\r\n originalPriceText: resources.originalPriceText,\r\n currentPriceText: resources.currentPriceText\r\n };\r\n}\r\n\r\n/**\r\n * To generate DuplicateItemsWhenAddingToOrderTemplateDialog resources.\r\n * @param resources - The resources.\r\n * @returns -- Returns the list of DuplicateItemsWhenAddingToOrderTemplateDialog resources..\r\n */\r\nfunction generateDuplicateItemsWhenAddingToOrderTemplateDialogResources(\r\n resources: IBuyboxCommonResources\r\n): IDuplicateItemsWhenAddingToOrderTemplateDialogResources {\r\n return {\r\n duplicatedProductsHeader: resources.duplicatedProductsHeader,\r\n duplicatedProductsDescription: resources.duplicatedProductsDescription,\r\n updateQuantityButtonText: resources.updateQuantityButtonText,\r\n cancelDuplicateItemsButtonText: resources.cancelDuplicateItemsButtonText\r\n };\r\n}\r\n\r\n/**\r\n * Add to wishlist failed function.\r\n * @param callbacks -Buybox callbacks.\r\n * @param resources -Buybox resources.\r\n * @param product -Simple product.\r\n * @returns Update error state.\r\n */\r\nconst onAddToOrderTemplateFailed = (callbacks: IBuyboxCallbacks, resources: IBuyboxCommonResources, product: SimpleProduct | undefined) => (\r\n result: IOrderTemplateActionErrorResult\r\n) => {\r\n callbacks.updateErrorState({\r\n errorHost: 'ORDER_TEMPLATE',\r\n configureErrors:\r\n result.status === 'MISSING_DIMENSION' ? getConfigureErrors(result.missingDimensions, resources, product?.IsGiftCard) : {}\r\n });\r\n};\r\n\r\n/**\r\n * RenderAddToOrderTemplateButton.\r\n * @param props - Buybox view props.\r\n * @param state - Buybox state.\r\n * @param callbacks - Buybox callbacks.\r\n * @param product - Product data.\r\n * @returns -- Returns JSX element.\r\n */\r\nexport const renderAddToOrderTemplateButton = (\r\n props: IBuyboxViewProps & IBuyboxExtentionProps,\r\n state: IBuyboxState,\r\n callbacks: IBuyboxCallbacks,\r\n product: SimpleProduct\r\n): React.ReactNode => {\r\n const {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from module file.\r\n id,\r\n typeName,\r\n context,\r\n data: {\r\n orderTemplates: { result: orderTemplates },\r\n customerInformation: { result: customerInformation }\r\n },\r\n resources\r\n } = props;\r\n\r\n const { quantity } = state;\r\n\r\n const isShowButtonText = true;\r\n\r\n return (\r\n orderTemplates && (\r\n \r\n )\r\n );\r\n};\r\n","/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n */\r\n\r\nimport { Text } from '@msdyn365-commerce/core';\r\nimport { AddToWishlistComponent, IWishlistActionErrorResult } from '@msdyn365-commerce/components';\r\nimport { format, ItemAvailability, SimpleProduct } from '@msdyn365-commerce/retail-proxy';\r\nimport { IStoreInfo } from '@msdyn365-commerce-modules/bopis-utilities';\r\nimport {\r\n getConfigureErrors,\r\n IBuyboxAddToCartViewProps,\r\n IBuyboxCallbacks,\r\n IBuyboxCommonResources,\r\n IBuyboxFindInStoreViewProps,\r\n IBuyboxKeyInPriceViewProps,\r\n IBuyboxProductConfigureDropdownViewProps,\r\n IBuyboxProductConfigureViewProps,\r\n IBuyboxProductQuantityViewProps,\r\n IBuyboxResources as IBuyboxExtentionResources,\r\n IBuyboxShopSimilarLookViewProps,\r\n IBuyboxState,\r\n IBuyboxViewProps\r\n} from '@msdyn365-commerce-modules/buybox';\r\nimport {\r\n ArrayExtensions,\r\n getFullAvailableInventoryNearby,\r\n GetFullAvailableInventoryNearbyInput,\r\n IFullOrgUnitAvailability\r\n} from '@msdyn365-commerce-modules/retail-actions';\r\nimport { IncrementalQuantity, INodeProps, ITelemetryContent, Module, Node } from '@msdyn365-commerce-modules/utilities';\r\nimport { reaction } from 'mobx';\r\nimport * as React from 'react';\r\nimport { IBuyboxProps as IBuyboxExtentionProps, IBuyboxProps } from '../definition-extensions/buybox.ext.props.autogenerated';\r\nimport { renderAddToOrderTemplateButton } from './components/buybox-add-to-order-template';\r\nimport { IBuyboxData } from './buybox.data';\r\nimport { BazaarVoiceStars, BazaarVoiceReviewOverview } from '../../../components/review.view';\r\n\r\n/**\r\n * BuyBoxConstants enum.\r\n */\r\nexport enum BuyBoxConstants {\r\n zero = 0\r\n}\r\n\r\n/**\r\n * On Change function.\r\n * @param callbacks -Callbacks.\r\n * @returns Update quantity.\r\n */\r\nconst onChangeHandler = (callbacks: IBuyboxCallbacks) => (newValue: number): boolean => {\r\n if (callbacks.updateQuantity) {\r\n return callbacks.updateQuantity(newValue);\r\n }\r\n return true;\r\n};\r\n\r\n/**\r\n * RenderQuantity.\r\n * @param quantityComponent - QuantityComponent.\r\n * @param callbacks - Callbacks.\r\n * @param props - Props.\r\n * @param state - State.\r\n * @param extentionResources - ExtentionResources.\r\n * @param quantityLimitsMessages - QuantityLimitsMessages.\r\n * @param max - Max.\r\n * @param telemetryContent - TelemetryContent.\r\n * @param unitOfMeasure - Unit Of Measure.\r\n * @returns -- Returns.\r\n */\r\nconst renderQuantity = (\r\n quantityComponent: IBuyboxProductQuantityViewProps,\r\n callbacks: IBuyboxCallbacks,\r\n props: IBuyboxProps,\r\n state: IBuyboxState,\r\n extentionResources: IBuyboxExtentionResources,\r\n quantityLimitsMessages: React.ReactNode,\r\n\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n max: number | undefined,\r\n telemetryContent?: ITelemetryContent,\r\n unitOfMeasure?: React.ReactNode\r\n): JSX.Element => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const { ContainerProps, LabelContainerProps, heading, errors } = quantityComponent;\r\n\r\n const { resources } = props;\r\n\r\n const { quantity } = state;\r\n\r\n return (\r\n \r\n \r\n {heading}\r\n {errors}\r\n \r\n\r\n \r\n {unitOfMeasure}\r\n {quantityLimitsMessages}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * Render key in price function.\r\n * @param keyInPrice - KeyInPrice.\r\n * @returns -- Returns.\r\n */\r\nconst renderKeyInPrice = (keyInPrice: IBuyboxKeyInPriceViewProps): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, input } = keyInPrice;\r\n\r\n return (\r\n \r\n {heading}\r\n {input}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderAddToCart.\r\n * @param addToCart - AddToCart.\r\n * @returns -- Returns.\r\n */\r\nconst renderAddToCart = (addToCart: IBuyboxAddToCartViewProps): JSX.Element => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const { ContainerProps, errorBlock, button } = addToCart;\r\n\r\n return (\r\n \r\n {errorBlock}\r\n {button}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderFindInStore.\r\n * @param findInStore - FindInStore.\r\n * @returns -- Returns.\r\n */\r\nconst renderFindInStore = (findInStore: IBuyboxFindInStoreViewProps): JSX.Element => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const { ContainerProps, storeSelector, heading, description, errors, button, modal, productPickupOptionList } = findInStore;\r\n\r\n return (\r\n \r\n {storeSelector}\r\n {heading}\r\n {productPickupOptionList}\r\n {description}\r\n {errors}\r\n {button}\r\n {modal}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderAddToOrderTemplate.\r\n * @param props - Buybox view props.\r\n * @param state - Buybox state.\r\n * @param callbacks - Buybox callbacks.\r\n * @returns -- Returns.\r\n */\r\nconst renderAddToOrderTemplate = (\r\n props: IBuyboxViewProps & IBuyboxExtentionProps,\r\n state: IBuyboxState,\r\n callbacks: IBuyboxCallbacks\r\n): JSX.Element | null => {\r\n const product = props.data.product.result;\r\n if (!props.addToOrderTemplate || !product) {\r\n return null;\r\n }\r\n\r\n const orderTemplateButton = renderAddToOrderTemplateButton(props, state, callbacks, product);\r\n\r\n return (\r\n \r\n {props.addToOrderTemplate.errorBlock}\r\n {orderTemplateButton}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * Add to wishlist failed function.\r\n * @param callbacks -Buybox callbacks.\r\n * @param resources -Buybox resources.\r\n * @param product -Simple product.\r\n * @returns Update error state.\r\n */\r\nconst onAddToWishlistFailed = (callbacks: IBuyboxCallbacks, resources: IBuyboxCommonResources, product: SimpleProduct | undefined) => (\r\n result: IWishlistActionErrorResult\r\n) => {\r\n callbacks.updateErrorState({\r\n errorHost: 'WISHLIST',\r\n configureErrors:\r\n result.status === 'MISSINGDIMENSION' ? getConfigureErrors(result.missingDimensions, resources, product?.IsGiftCard) : {}\r\n });\r\n};\r\n\r\n/**\r\n * RenderAddToWishlist.\r\n * @param props - Buybox view props.\r\n * @param state - Buybox state.\r\n * @param callbacks - Buybox callbacks.\r\n * @param product - Product data.\r\n * @returns -- Returns.\r\n */\r\nconst renderAddtoWishlistButton = (\r\n props: IBuyboxViewProps & IBuyboxExtentionProps,\r\n state: IBuyboxState,\r\n callbacks: IBuyboxCallbacks,\r\n product: SimpleProduct\r\n): React.ReactNode => {\r\n const { context, resources } = props;\r\n const wishlists = props.data.wishlists.result;\r\n const isShowWishlitButtonText = true;\r\n return (\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderAddToWishlist.\r\n * @param props - Buybox viewprops.\r\n * @param state - Buybox state.\r\n * @param callbacks - Buybox callbacks.\r\n * @returns -- Returns.\r\n */\r\nconst renderAddToWishlist = (\r\n props: IBuyboxViewProps & IBuyboxExtentionProps,\r\n state: IBuyboxState,\r\n callbacks: IBuyboxCallbacks\r\n): JSX.Element | null => {\r\n const product = props.data.product.result;\r\n if (!props.addToWishlist || !product) {\r\n return null;\r\n }\r\n\r\n if (!props.config.enableWishlist) {\r\n return null;\r\n }\r\n\r\n const wishlistButton = renderAddtoWishlistButton(props, state, callbacks, product);\r\n return (\r\n \r\n {props.addToWishlist.errorBlock}\r\n {wishlistButton}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RRenderShopSimilarItem.\r\n * @param shopSimilarItem - ShopSimilarItem.\r\n * @returns -- Returns.\r\n */\r\nconst renderShopSimilarItem = (shopSimilarItem: IBuyboxShopSimilarLookViewProps): JSX.Element => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const { ContainerProps, errors, input } = shopSimilarItem;\r\n\r\n return (\r\n \r\n {errors}\r\n {input}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderSocialShare.\r\n * @param socialShare - Social share react node array.\r\n * @returns -- Returns.\r\n */\r\nconst _renderSocialShare = (socialShare: React.ReactNode[]): JSX.Element | undefined => {\r\n if (!socialShare || socialShare.length === 0) {\r\n return undefined;\r\n }\r\n\r\n return <>{socialShare[0]};\r\n};\r\n\r\n/**\r\n * RenderConfigureDropdown.\r\n * @param dropdown - Buybox product configure dropdown view props.\r\n * @returns -- Returns JSX.Element.\r\n */\r\nconst renderConfigureDropdown = (dropdown: IBuyboxProductConfigureDropdownViewProps): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, errors, select } = dropdown;\r\n\r\n return (\r\n \r\n {heading}\r\n {select}\r\n {errors}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderConfigure.\r\n * @param configure - Buybox product configure view props.\r\n * @returns -- Returns JSX.Element.\r\n */\r\nconst renderConfigure = (configure: IBuyboxProductConfigureViewProps): JSX.Element => {\r\n const { ContainerProps, dropdowns } = configure;\r\n\r\n return {dropdowns.map(renderConfigureDropdown)};\r\n};\r\n\r\n/**\r\n * BuyboxView.\r\n * @param props - Props.\r\n * @returns -- Returns.\r\n */\r\nconst BuyboxView: React.FC> = props => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const {\r\n ModuleProps,\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n MediaGalleryContainerProps,\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n ProductInfoContainerProps,\r\n addToCart,\r\n addToOrderTemplate,\r\n addToWishlist,\r\n productComparisonButton,\r\n configure,\r\n description,\r\n findInStore,\r\n quantity,\r\n price,\r\n title,\r\n inventoryLabel,\r\n shopSimilarLook,\r\n keyInPrice,\r\n shopSimilarDescription,\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n max,\r\n unitOfMeasure,\r\n callbacks,\r\n state,\r\n resources,\r\n quantityLimitsMessages,\r\n telemetryContent,\r\n app: { config: appConfig },\r\n catalogs\r\n } = props;\r\n let skuText: string = props.resources.skuText;\r\n skuText += props.data.product.result?.ItemId;\r\n const preferredStoreInfo: IStoreInfo | undefined = props.data.storeSelectorStateManager.result?.preferredStore;\r\n const preferredStoreId = preferredStoreInfo?.StoreId ? preferredStoreInfo.StoreId : '';\r\n const preferredStoreName = preferredStoreInfo?.StoreName ? preferredStoreInfo.StoreName : '';\r\n\r\n const [availability, setAvailability] = React.useState('');\r\n const [isStoreChange, setIsStoreChange] = React.useState(false);\r\n\r\n /**\r\n * GetStockInventoryLabel.\r\n * @param availabilityWithHours - Stock availability with hours.\r\n * @returns -- Returns.\r\n */\r\n const getStockInventoryLabel = (availabilityWithHours: IFullOrgUnitAvailability | undefined): string | undefined => {\r\n if (availabilityWithHours && ArrayExtensions.hasElements(availabilityWithHours.ProductInventoryInformation)) {\r\n for (const productInventoryInformation of availabilityWithHours.ProductInventoryInformation) {\r\n if (\r\n availabilityWithHours.OrgUnitAvailability?.OrgUnitLocation?.InventoryLocationId ===\r\n productInventoryInformation.InventLocationId\r\n ) {\r\n return productInventoryInformation.StockLevelLabel;\r\n }\r\n }\r\n }\r\n\r\n return undefined;\r\n };\r\n\r\n const getInventory = React.useCallback(async () => {\r\n const input = new GetFullAvailableInventoryNearbyInput(\r\n props.data.product.result?.RecordId,\r\n BuyBoxConstants.zero,\r\n BuyBoxConstants.zero,\r\n BuyBoxConstants.zero,\r\n BuyBoxConstants.zero,\r\n true\r\n );\r\n\r\n /**\r\n * IsProductInStock.\r\n * @param itemAvailabilities - Item availability array.\r\n * @returns -- Returns.\r\n */\r\n const isProductInStock = (itemAvailabilities: ItemAvailability[] | undefined): boolean => {\r\n if (!appConfig.enableStockCheck) {\r\n return true;\r\n }\r\n\r\n if (ArrayExtensions.hasElements(itemAvailabilities)) {\r\n return itemAvailabilities[BuyBoxConstants.zero].AvailableQuantity! > BuyBoxConstants.zero;\r\n }\r\n\r\n return false;\r\n };\r\n\r\n await getFullAvailableInventoryNearby(input, props.context.actionContext)\r\n .catch((error: Error) => {\r\n props.telemetry.error(error.message);\r\n })\r\n .then(response => {\r\n if (response && ArrayExtensions.hasElements(response)) {\r\n const isPreferredStore = (value: IFullOrgUnitAvailability) =>\r\n value.OrgUnitAvailability?.OrgUnitLocation?.OrgUnitNumber === preferredStoreId;\r\n const filteredFullOrgUnitAvailability = response.filter(isPreferredStore);\r\n const preferredStoreAvailability = ArrayExtensions.hasElements(filteredFullOrgUnitAvailability)\r\n ? filteredFullOrgUnitAvailability[BuyBoxConstants.zero]\r\n : undefined;\r\n const stockStatusLabel: string | undefined = getStockInventoryLabel(preferredStoreAvailability);\r\n const isInStock = isProductInStock(preferredStoreAvailability?.OrgUnitAvailability?.ItemAvailabilities);\r\n const resourceLabel = isInStock ? props.resources.inStockText : props.resources.outOfStockText;\r\n const stockText: string | undefined = stockStatusLabel ? stockStatusLabel : resourceLabel;\r\n const preferredStoreAvailabilityText = `${format(\r\n props.resources.availabilityAtPreferredStoreText,\r\n preferredStoreName\r\n )} ${stockText}`;\r\n setAvailability(preferredStoreAvailabilityText);\r\n }\r\n });\r\n\r\n setIsStoreChange(false);\r\n }, [\r\n props.data.product.result?.RecordId,\r\n appConfig.enableStockCheck,\r\n preferredStoreId,\r\n preferredStoreName,\r\n props.context.actionContext,\r\n props.resources.availabilityAtPreferredStoreText,\r\n props.resources.inStockText,\r\n props.resources.outOfStockText,\r\n props.telemetry\r\n ]);\r\n\r\n React.useEffect(() => {\r\n if (props.config.displayStockAvailability) {\r\n getInventory().catch((error: Error) => {\r\n props.telemetry.error(error.message);\r\n });\r\n }\r\n }, [getInventory, isStoreChange, props.telemetry, props.config.displayStockAvailability]);\r\n\r\n reaction(\r\n () => props.data.storeSelectorStateManager.result?.selectedStoreLocationId,\r\n () => {\r\n setIsStoreChange(true);\r\n }\r\n );\r\n\r\n /**\r\n * RenderAvailabiltyAtPreferredStore.\r\n * @returns -- Returns.\r\n */\r\n const renderAvailabilityAtPreferredStore = (): JSX.Element | undefined => {\r\n const hasProductDimensions = ArrayExtensions.hasElements(props.data.product.result?.Dimensions);\r\n if (hasProductDimensions && props.data.product.result?.MasterProductId === undefined) {\r\n return undefined;\r\n }\r\n const containerProps: INodeProps = {\r\n className: 'ms-buybox__preferred-store-availability',\r\n tag: 'span'\r\n };\r\n\r\n return {availability};\r\n };\r\n\r\n const descriptionNode = (node: React.ReactNode): string => {\r\n if (!node) {\r\n return '';\r\n }\r\n const nodeEl = node as JSX.Element;\r\n const DescriptionObject = nodeEl.props.children;\r\n return DescriptionObject;\r\n };\r\n\r\n const scrollToReviews = (): void => {\r\n const offsetTop: number | undefined = document.getElementById('product-customer-reviews')?.offsetTop;\r\n if (offsetTop) {\r\n window.scrollTo({ top: offsetTop, behavior: 'smooth' });\r\n }\r\n };\r\n\r\n const productSize = props.data.productSpecificationData.result?.find(result => result.Name === appConfig.productSizeAttributeName);\r\n const brandName = props.data.productSpecificationData.result?.find(result => result.Name === appConfig.brandNameAttributeName);\r\n const productUnit = props.data.productSpecificationData.result?.find(result => result.Name === appConfig.productUnitAttributeName);\r\n const productIngredient = props.data.productSpecificationData.result?.find(\r\n result => result.Name === appConfig.productIngredientAttributeName\r\n );\r\n return (\r\n \r\n {props.mediaGallery}\r\n \r\n

\r\n {brandName?.TextValue}\r\n {catalogs && catalogs[0].Name}\r\n

\r\n {title}\r\n
\r\n \r\n
\r\n
\r\n \r\n {props.resources.sizeText} {productSize?.FloatValue} {productUnit?.TextValue}\r\n \r\n
\r\n \r\n
{skuText}
\r\n
\r\n\r\n \r\n
{props.resources.priceText}
\r\n {price}\r\n
\r\n {configure && renderConfigure(configure)}\r\n {keyInPrice && renderKeyInPrice(keyInPrice)}\r\n \r\n
\r\n {quantity &&\r\n renderQuantity(\r\n quantity,\r\n callbacks,\r\n props,\r\n state,\r\n resources,\r\n quantityLimitsMessages,\r\n max,\r\n telemetryContent,\r\n unitOfMeasure\r\n )}\r\n {props.bulkPurchaseLink}\r\n {props.config.stockAvailableText}\r\n
\r\n
\r\n {props.config.displayStockAvailability && preferredStoreId && renderAvailabilityAtPreferredStore()}\r\n {inventoryLabel}\r\n {renderAddToCart(addToCart)}\r\n {findInStore && renderFindInStore(findInStore)}\r\n {addToWishlist && renderAddToWishlist(props, state, callbacks)}\r\n {productComparisonButton}\r\n {addToOrderTemplate && renderAddToOrderTemplate(props, state, callbacks)}\r\n {/* {findInStore?.productPickupOptionList ? (\r\n
{findInStore.productPickupOptionList}
\r\n ) : null} */}\r\n {_renderSocialShare(props.slots && props.slots.socialShare)}\r\n {/*
{props.resources.shopText}
*/}\r\n\r\n \r\n {shopSimilarLook && renderShopSimilarItem(shopSimilarLook)}\r\n {shopSimilarDescription && renderShopSimilarItem(shopSimilarDescription)}\r\n \r\n \r\n
{props.resources.descriptionText}
\r\n \r\n {productIngredient && productIngredient.TextValue !== '' && (\r\n \r\n )}\r\n {/* {description} */}\r\n
\r\n {ArrayExtensions.hasElements(props.slots.productSpecification) ? (\r\n {props.slots.productSpecification[0]}\r\n ) : null}\r\n
\r\n \r\n
\r\n
\r\n
\r\n );\r\n};\r\n\r\nexport default BuyboxView;\r\n","/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n */\r\n\r\nimport {\r\n AddToOrderTemplateComponent,\r\n IAddToOrderTemplateDialogResources,\r\n IDuplicateItemsWhenAddingToOrderTemplateDialogResources,\r\n IItemAddedToOrderTemplateDialogResources,\r\n IOrderTemplateActionErrorResult,\r\n IOrderTemplateNameDialogResources\r\n} from '@msdyn365-commerce/components';\r\nimport { SimpleProduct } from '@msdyn365-commerce/retail-proxy';\r\nimport {\r\n getConfigureErrors,\r\n IBuyboxCallbacks,\r\n IBuyboxCommonResources,\r\n IBuyboxData,\r\n IBuyboxState,\r\n IBuyboxViewProps\r\n} from '@msdyn365-commerce-modules/buybox';\r\nimport * as React from 'react';\r\n\r\nimport { IBuyboxProps as IBuyboxExtentionProps } from '../../definition-extensions/buybox.ext.props.autogenerated';\r\n\r\n/**\r\n * To generate AddToOrderTemplateDialog resources.\r\n * @param resources - The resources.\r\n * @returns -- Returns the list of AddToOrderTemplateDialog resources..\r\n */\r\nfunction generateAddToOrderTemplateDialogResources(resources: IBuyboxCommonResources): IAddToOrderTemplateDialogResources {\r\n return {\r\n addToOrderTemplateHeader: resources.addToOrderTemplateHeader,\r\n\r\n noOrderTemplatesMessage: resources.noOrderTemplatesMessage,\r\n noOrderTemplatesDescription: resources.noOrderTemplatesDescription,\r\n\r\n createAnOrderTemplateButtonText: resources.createAnOrderTemplateButtonText,\r\n createNewOrderTemplateButtonText: resources.createNewOrderTemplateButtonText,\r\n cancelOrderTemplateCreationButtonText: resources.cancelOrderTemplateCreationButtonText,\r\n\r\n selectTemplatesText: resources.selectTemplatesText,\r\n addToTemplateButtonText: resources.addToTemplateButtonText,\r\n lineItemsText: resources.lineItemsText\r\n };\r\n}\r\n\r\n/**\r\n * To generate OrderTemplateNameDialog resources.\r\n * @param resources - The resources.\r\n * @returns -- Returns the list of OrderTemplateNameDialog resources..\r\n */\r\nfunction generateOrderTemplateNameDialogResources(resources: IBuyboxCommonResources): IOrderTemplateNameDialogResources {\r\n return {\r\n orderTemplateHeaderLabel: resources.createOrderTemplateHeader,\r\n orderTemplateTitleLabel: resources.orderTemplateTitle,\r\n orderTemplateNameAriaLabel: resources.orderTemplateNameAriaLabel,\r\n orderTemplateDescription: resources.createOrderTemplateDescription,\r\n\r\n defaultOrderTemplateName: resources.defaultOrderTemplateName,\r\n\r\n orderTemplateButtonLabel: resources.createOrderTemplateButtonText,\r\n orderTemplateCancelButtonLabel: resources.cancelNewOrderTemplateCreationButtonText\r\n };\r\n}\r\n\r\n/**\r\n * To generate ItemAddedToOrderTemplateDialog resources.\r\n * @param resources - The resources.\r\n * @returns -- Returns the list of ItemAddedToOrderTemplateDialog resources..\r\n */\r\nfunction generateItemAddedToOrderTemplateDialogResources(resources: IBuyboxCommonResources): IItemAddedToOrderTemplateDialogResources {\r\n return {\r\n viewOrderTemplateButtonText: resources.viewOrderTemplateButtonText,\r\n continueShoppingButtonText: resources.continueShoppingButtonText,\r\n itemAddedToOrderTemplateHeaderItemOneText: resources.itemAddedToOrderTemplateHeaderItemOneText,\r\n itemAddedToOrderTemplateHeaderItemFormatText: resources.itemAddedToOrderTemplateHeaderItemFormatText,\r\n itemAddedToOrderTemplateHeaderMessageText: resources.itemAddedToOrderTemplateHeaderMessageText,\r\n freePriceText: resources.priceFree,\r\n originalPriceText: resources.originalPriceText,\r\n currentPriceText: resources.currentPriceText\r\n };\r\n}\r\n\r\n/**\r\n * To generate DuplicateItemsWhenAddingToOrderTemplateDialog resources.\r\n * @param resources - The resources.\r\n * @returns -- Returns the list of DuplicateItemsWhenAddingToOrderTemplateDialog resources..\r\n */\r\nfunction generateDuplicateItemsWhenAddingToOrderTemplateDialogResources(\r\n resources: IBuyboxCommonResources\r\n): IDuplicateItemsWhenAddingToOrderTemplateDialogResources {\r\n return {\r\n duplicatedProductsHeader: resources.duplicatedProductsHeader,\r\n duplicatedProductsDescription: resources.duplicatedProductsDescription,\r\n updateQuantityButtonText: resources.updateQuantityButtonText,\r\n cancelDuplicateItemsButtonText: resources.cancelDuplicateItemsButtonText\r\n };\r\n}\r\n\r\n/**\r\n * Add to wishlist failed function.\r\n * @param callbacks -Buybox callbacks.\r\n * @param resources -Buybox resources.\r\n * @param product -Simple product.\r\n * @returns Update error state.\r\n */\r\nconst onAddToOrderTemplateFailed = (callbacks: IBuyboxCallbacks, resources: IBuyboxCommonResources, product: SimpleProduct | undefined) => (\r\n result: IOrderTemplateActionErrorResult\r\n) => {\r\n callbacks.updateErrorState({\r\n errorHost: 'ORDER_TEMPLATE',\r\n configureErrors:\r\n result.status === 'MISSING_DIMENSION' ? getConfigureErrors(result.missingDimensions, resources, product?.IsGiftCard) : {}\r\n });\r\n};\r\n\r\n/**\r\n * RenderAddToOrderTemplateButton.\r\n * @param props - Buybox view props.\r\n * @param state - Buybox state.\r\n * @param callbacks - Buybox callbacks.\r\n * @param product - Product data.\r\n * @returns -- Returns JSX element.\r\n */\r\nexport const renderAddToOrderTemplateButton = (\r\n props: IBuyboxViewProps & IBuyboxExtentionProps,\r\n state: IBuyboxState,\r\n callbacks: IBuyboxCallbacks,\r\n product: SimpleProduct\r\n): React.ReactNode => {\r\n const {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from module file.\r\n id,\r\n typeName,\r\n context,\r\n data: {\r\n orderTemplates: { result: orderTemplates },\r\n customerInformation: { result: customerInformation }\r\n },\r\n resources,\r\n config\r\n } = props;\r\n\r\n const { quantity } = state;\r\n\r\n const isShowButtonText = true;\r\n const isMultipleCatalogsFeatureEnabled = props.isChannelMultipleCatalogsFeatureEnabled || false;\r\n return (\r\n orderTemplates && (\r\n \r\n )\r\n );\r\n};\r\n","/*!\r\n * Copyright (c) Microsoft Corporation.\r\n * All rights reserved. See LICENSE in the project root for license information.\r\n */\r\n\r\nimport { Text } from '@msdyn365-commerce/core';\r\nimport { AddToWishlistComponent, IWishlistActionErrorResult } from '@msdyn365-commerce/components';\r\nimport { format, ItemAvailability, SimpleProduct } from '@msdyn365-commerce/retail-proxy';\r\nimport { IStoreInfo } from '@msdyn365-commerce-modules/bopis-utilities';\r\nimport {\r\n getConfigureErrors,\r\n IBuyboxAddToCartViewProps,\r\n IBuyboxCallbacks,\r\n IBuyboxCommonResources,\r\n IBuyboxFindInStoreViewProps,\r\n IBuyboxKeyInPriceViewProps,\r\n IBuyboxProductConfigureDropdownViewProps,\r\n IBuyboxProductConfigureViewProps,\r\n IBuyboxProductQuantityViewProps,\r\n IBuyboxResources as IBuyboxExtentionResources,\r\n IBuyboxShopSimilarLookViewProps,\r\n IBuyboxState,\r\n IBuyboxViewProps\r\n} from '@msdyn365-commerce-modules/buybox';\r\nimport {\r\n ArrayExtensions,\r\n getFullAvailableInventoryNearby,\r\n GetFullAvailableInventoryNearbyInput,\r\n IFullOrgUnitAvailability\r\n} from '@msdyn365-commerce-modules/retail-actions';\r\nimport { IncrementalQuantity, INodeProps, ITelemetryContent, Module, Node } from '@msdyn365-commerce-modules/utilities';\r\nimport { reaction } from 'mobx';\r\nimport * as React from 'react';\r\n\r\nimport { IBuyboxProps as IBuyboxExtentionProps, IBuyboxProps } from '../definition-extensions/buybox.ext.props.autogenerated';\r\nimport { renderAddToOrderTemplateButton } from './components/buybox-add-to-order-template';\r\nimport { IBuyboxData } from './buybox.data';\r\nimport { BazaarVoiceReviewOverview, BazaarVoiceStars } from '../../../components/review.view';\r\n\r\n/**\r\n * BuyBoxConstants enum.\r\n */\r\nexport enum BuyBoxConstants {\r\n zero = 0\r\n}\r\n\r\n/**\r\n * On Change function.\r\n * @param callbacks -Callbacks.\r\n * @returns Update quantity.\r\n */\r\nconst onChangeHandler = (callbacks: IBuyboxCallbacks) => (newValue: number): boolean => {\r\n if (callbacks.updateQuantity) {\r\n return callbacks.updateQuantity(newValue);\r\n }\r\n return true;\r\n};\r\n\r\n/**\r\n * RenderQuantity.\r\n * @param quantityComponent - QuantityComponent.\r\n * @param callbacks - Callbacks.\r\n * @param props - Props.\r\n * @param state - State.\r\n * @param extentionResources - ExtentionResources.\r\n * @param quantityLimitsMessages - QuantityLimitsMessages.\r\n * @param max - Max.\r\n * @param telemetryContent - TelemetryContent.\r\n * @param unitOfMeasure - Unit Of Measure.\r\n * @returns -- Returns.\r\n */\r\nconst renderQuantity = (\r\n quantityComponent: IBuyboxProductQuantityViewProps,\r\n callbacks: IBuyboxCallbacks,\r\n props: IBuyboxProps,\r\n state: IBuyboxState,\r\n extentionResources: IBuyboxExtentionResources,\r\n quantityLimitsMessages: React.ReactNode,\r\n\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n max: number | undefined,\r\n telemetryContent?: ITelemetryContent,\r\n unitOfMeasure?: React.ReactNode\r\n): JSX.Element => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const { ContainerProps, LabelContainerProps, heading, errors } = quantityComponent;\r\n\r\n const { resources } = props;\r\n\r\n const { quantity } = state;\r\n\r\n return (\r\n \r\n \r\n {heading}\r\n {errors}\r\n \r\n\r\n \r\n {unitOfMeasure}\r\n {quantityLimitsMessages}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * Render key in price function.\r\n * @param keyInPrice - KeyInPrice.\r\n * @returns -- Returns.\r\n */\r\nconst renderKeyInPrice = (keyInPrice: IBuyboxKeyInPriceViewProps): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, input } = keyInPrice;\r\n\r\n return (\r\n \r\n {heading}\r\n {input}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderAddToCart.\r\n * @param addToCart - AddToCart.\r\n * @returns -- Returns.\r\n */\r\nconst renderAddToCart = (addToCart: IBuyboxAddToCartViewProps): JSX.Element => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const { ContainerProps, errorBlock, button } = addToCart;\r\n\r\n return (\r\n \r\n {errorBlock}\r\n {button}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderFindInStore.\r\n * @param findInStore - FindInStore.\r\n * @returns -- Returns.\r\n */\r\nconst renderFindInStore = (findInStore: IBuyboxFindInStoreViewProps): JSX.Element => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const { ContainerProps, storeSelector, heading, description, errors, button, modal, productPickupOptionList } = findInStore;\r\n\r\n return (\r\n \r\n {storeSelector}\r\n {heading}\r\n {productPickupOptionList}\r\n {description}\r\n {errors}\r\n {button}\r\n {modal}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderAddToOrderTemplate.\r\n * @param props - Buybox view props.\r\n * @param state - Buybox state.\r\n * @param callbacks - Buybox callbacks.\r\n * @returns -- Returns.\r\n */\r\nconst renderAddToOrderTemplate = (\r\n props: IBuyboxViewProps & IBuyboxExtentionProps,\r\n state: IBuyboxState,\r\n callbacks: IBuyboxCallbacks\r\n): JSX.Element | null => {\r\n const product = props.data.product.result;\r\n if (!props.addToOrderTemplate || !product) {\r\n return null;\r\n }\r\n\r\n const orderTemplateButton = renderAddToOrderTemplateButton(props, state, callbacks, product);\r\n\r\n return (\r\n \r\n {props.addToOrderTemplate.errorBlock}\r\n {orderTemplateButton}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * Add to wishlist failed function.\r\n * @param callbacks -Buybox callbacks.\r\n * @param resources -Buybox resources.\r\n * @param product -Simple product.\r\n * @returns Update error state.\r\n */\r\nconst onAddToWishlistFailed = (callbacks: IBuyboxCallbacks, resources: IBuyboxCommonResources, product: SimpleProduct | undefined) => (\r\n result: IWishlistActionErrorResult\r\n) => {\r\n callbacks.updateErrorState({\r\n errorHost: 'WISHLIST',\r\n configureErrors:\r\n result.status === 'MISSINGDIMENSION' ? getConfigureErrors(result.missingDimensions, resources, product?.IsGiftCard) : {}\r\n });\r\n};\r\n\r\n/**\r\n * RenderAddToWishlist.\r\n * @param props - Buybox view props.\r\n * @param state - Buybox state.\r\n * @param callbacks - Buybox callbacks.\r\n * @param product - Product data.\r\n * @returns -- Returns.\r\n */\r\nconst renderAddtoWishlistButton = (\r\n props: IBuyboxViewProps & IBuyboxExtentionProps,\r\n state: IBuyboxState,\r\n callbacks: IBuyboxCallbacks,\r\n product: SimpleProduct\r\n): React.ReactNode => {\r\n const { context, resources } = props;\r\n const wishlists = props.data.wishlists.result;\r\n const isShowWishlitButtonText = true;\r\n return (\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderAddToWishlist.\r\n * @param props - Buybox viewprops.\r\n * @param state - Buybox state.\r\n * @param callbacks - Buybox callbacks.\r\n * @returns -- Returns.\r\n */\r\nconst renderAddToWishlist = (\r\n props: IBuyboxViewProps & IBuyboxExtentionProps,\r\n state: IBuyboxState,\r\n callbacks: IBuyboxCallbacks\r\n): JSX.Element | null => {\r\n const product = props.data.product.result;\r\n if (!props.addToWishlist || !product) {\r\n return null;\r\n }\r\n\r\n if (!props.config.enableWishlist) {\r\n return null;\r\n }\r\n\r\n const wishlistButton = renderAddtoWishlistButton(props, state, callbacks, product);\r\n return (\r\n \r\n {props.addToWishlist.errorBlock}\r\n {wishlistButton}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RRenderShopSimilarItem.\r\n * @param shopSimilarItem - ShopSimilarItem.\r\n * @returns -- Returns.\r\n */\r\nconst renderShopSimilarItem = (shopSimilarItem: IBuyboxShopSimilarLookViewProps): JSX.Element => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const { ContainerProps, errors, input } = shopSimilarItem;\r\n\r\n return (\r\n \r\n {errors}\r\n {input}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderSocialShare.\r\n * @param socialShare - Social share react node array.\r\n * @returns -- Returns.\r\n */\r\nconst _renderSocialShare = (socialShare: React.ReactNode[]): JSX.Element | undefined => {\r\n if (!socialShare || socialShare.length === 0) {\r\n return undefined;\r\n }\r\n\r\n return <>{socialShare[0]};\r\n};\r\n\r\n/**\r\n * RenderConfigureDropdown.\r\n * @param dropdown - Buybox product configure dropdown view props.\r\n * @returns -- Returns JSX.Element.\r\n */\r\nconst renderConfigureDropdown = (dropdown: IBuyboxProductConfigureDropdownViewProps): JSX.Element => {\r\n const { ContainerProps, LabelContainerProps, heading, errors, select } = dropdown;\r\n\r\n return (\r\n \r\n {heading}\r\n {select}\r\n {errors}\r\n \r\n );\r\n};\r\n\r\n/**\r\n * RenderConfigure.\r\n * @param configure - Buybox product configure view props.\r\n * @returns -- Returns JSX.Element.\r\n */\r\nconst renderConfigure = (configure: IBuyboxProductConfigureViewProps): JSX.Element => {\r\n const { ContainerProps, dropdowns } = configure;\r\n\r\n return {dropdowns.map(renderConfigureDropdown)};\r\n};\r\n\r\n/**\r\n * BuyboxView.\r\n * @param props - Props.\r\n * @returns -- Returns.\r\n */\r\nconst BuyboxView: React.FC> = props => {\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n const {\r\n ModuleProps,\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n MediaGalleryContainerProps,\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n ProductInfoContainerProps,\r\n addToCart,\r\n addToOrderTemplate,\r\n addToWishlist,\r\n productComparisonButton,\r\n configure,\r\n description,\r\n findInStore,\r\n quantity,\r\n price,\r\n title,\r\n inventoryLabel,\r\n shopSimilarLook,\r\n keyInPrice,\r\n shopSimilarDescription,\r\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\r\n max,\r\n unitOfMeasure,\r\n callbacks,\r\n state,\r\n resources,\r\n quantityLimitsMessages,\r\n telemetryContent,\r\n app: { config: appConfig },\r\n catalogs\r\n } = props;\r\n let skuText: string = props.resources.skuText;\r\n skuText += props.data.product.result?.ItemId;\r\n const preferredStoreInfo: IStoreInfo | undefined = props.data.storeSelectorStateManager.result?.preferredStore;\r\n const preferredStoreId = preferredStoreInfo?.StoreId ? preferredStoreInfo.StoreId : '';\r\n const preferredStoreName = preferredStoreInfo?.StoreName ? preferredStoreInfo.StoreName : '';\r\n\r\n const [availability, setAvailability] = React.useState('');\r\n const [isStoreChange, setIsStoreChange] = React.useState(false);\r\n\r\n /**\r\n * GetStockInventoryLabel.\r\n * @param availabilityWithHours - Stock availability with hours.\r\n * @returns -- Returns.\r\n */\r\n const getStockInventoryLabel = (availabilityWithHours: IFullOrgUnitAvailability | undefined): string | undefined => {\r\n if (availabilityWithHours && ArrayExtensions.hasElements(availabilityWithHours.ProductInventoryInformation)) {\r\n for (const productInventoryInformation of availabilityWithHours.ProductInventoryInformation) {\r\n if (\r\n availabilityWithHours.OrgUnitAvailability?.OrgUnitLocation?.InventoryLocationId ===\r\n productInventoryInformation.InventLocationId\r\n ) {\r\n return productInventoryInformation.StockLevelLabel;\r\n }\r\n }\r\n }\r\n\r\n return undefined;\r\n };\r\n\r\n const getInventory = React.useCallback(async () => {\r\n const input = new GetFullAvailableInventoryNearbyInput(\r\n props.data.product.result?.RecordId,\r\n BuyBoxConstants.zero,\r\n BuyBoxConstants.zero,\r\n BuyBoxConstants.zero,\r\n BuyBoxConstants.zero,\r\n true\r\n );\r\n\r\n /**\r\n * IsProductInStock.\r\n * @param itemAvailabilities - Item availability array.\r\n * @returns -- Returns.\r\n */\r\n const isProductInStock = (itemAvailabilities: ItemAvailability[] | undefined): boolean => {\r\n if (!appConfig.enableStockCheck) {\r\n return true;\r\n }\r\n\r\n if (ArrayExtensions.hasElements(itemAvailabilities)) {\r\n return itemAvailabilities[BuyBoxConstants.zero].AvailableQuantity! > BuyBoxConstants.zero;\r\n }\r\n\r\n return false;\r\n };\r\n\r\n await getFullAvailableInventoryNearby(input, props.context.actionContext)\r\n .catch((error: Error) => {\r\n props.telemetry.error(error.message);\r\n })\r\n .then(response => {\r\n if (response && ArrayExtensions.hasElements(response)) {\r\n const isPreferredStore = (value: IFullOrgUnitAvailability) =>\r\n value.OrgUnitAvailability?.OrgUnitLocation?.OrgUnitNumber === preferredStoreId;\r\n const filteredFullOrgUnitAvailability = response.filter(isPreferredStore);\r\n const preferredStoreAvailability = ArrayExtensions.hasElements(filteredFullOrgUnitAvailability)\r\n ? filteredFullOrgUnitAvailability[BuyBoxConstants.zero]\r\n : undefined;\r\n const stockStatusLabel: string | undefined = getStockInventoryLabel(preferredStoreAvailability);\r\n const isInStock = isProductInStock(preferredStoreAvailability?.OrgUnitAvailability?.ItemAvailabilities);\r\n const resourceLabel = isInStock ? props.resources.inStockText : props.resources.outOfStockText;\r\n const stockText: string | undefined = stockStatusLabel ? stockStatusLabel : resourceLabel;\r\n const preferredStoreAvailabilityText = `${format(\r\n props.resources.availabilityAtPreferredStoreText,\r\n preferredStoreName\r\n )} ${stockText}`;\r\n setAvailability(preferredStoreAvailabilityText);\r\n }\r\n });\r\n\r\n setIsStoreChange(false);\r\n }, [\r\n props.data.product.result?.RecordId,\r\n appConfig.enableStockCheck,\r\n preferredStoreId,\r\n preferredStoreName,\r\n props.context.actionContext,\r\n props.resources.availabilityAtPreferredStoreText,\r\n props.resources.inStockText,\r\n props.resources.outOfStockText,\r\n props.telemetry\r\n ]);\r\n\r\n React.useEffect(() => {\r\n if (props.config.displayStockAvailability) {\r\n getInventory().catch((error: Error) => {\r\n props.telemetry.error(error.message);\r\n });\r\n }\r\n }, [getInventory, isStoreChange, props.telemetry, props.config.displayStockAvailability]);\r\n\r\n reaction(\r\n () => props.data.storeSelectorStateManager.result?.selectedStoreLocationId,\r\n () => {\r\n setIsStoreChange(true);\r\n }\r\n );\r\n\r\n /**\r\n * RenderAvailabiltyAtPreferredStore.\r\n * @returns -- Returns.\r\n */\r\n const renderAvailabilityAtPreferredStore = (): JSX.Element | undefined => {\r\n const hasProductDimensions = ArrayExtensions.hasElements(props.data.product.result?.Dimensions);\r\n if (hasProductDimensions && props.data.product.result?.MasterProductId === undefined) {\r\n return undefined;\r\n }\r\n const containerProps: INodeProps = {\r\n className: 'ms-buybox__preferred-store-availability',\r\n tag: 'span'\r\n };\r\n\r\n return {availability};\r\n };\r\n\r\n const descriptionNode = (node: React.ReactNode): string => {\r\n if (!node) {\r\n return '';\r\n }\r\n const nodeEl = node as JSX.Element;\r\n const DescriptionObject = nodeEl.props.children;\r\n return DescriptionObject;\r\n };\r\n\r\n const scrollToReviews = (): void => {\r\n const offsetTop: number | undefined = document.getElementById('product-customer-reviews')?.offsetTop;\r\n if (offsetTop) {\r\n window.scrollTo({ top: offsetTop, behavior: 'smooth' });\r\n }\r\n };\r\n\r\n const productSize = props.data.productSpecificationData.result?.find(result => result.Name === appConfig.productSizeAttributeName);\r\n const brandName = props.data.productSpecificationData.result?.find(result => result.Name === appConfig.brandNameAttributeName);\r\n const productUnit = props.data.productSpecificationData.result?.find(result => result.Name === appConfig.productUnitAttributeName);\r\n const productIngredient = props.data.productSpecificationData.result?.find(\r\n result => result.Name === appConfig.productIngredientAttributeName\r\n );\r\n\r\n return (\r\n \r\n {props.mediaGallery}\r\n \r\n

\r\n {brandName?.TextValue}\r\n {catalogs && catalogs[0].Name}\r\n

\r\n {title}\r\n
\r\n \r\n
\r\n
\r\n \r\n {props.resources.sizeText} {productSize?.FloatValue} {productUnit?.TextValue}\r\n \r\n
\r\n \r\n
{skuText}
\r\n
\r\n\r\n \r\n
{props.resources.priceText}
\r\n {price}\r\n
\r\n {configure && renderConfigure(configure)}\r\n {keyInPrice && renderKeyInPrice(keyInPrice)}\r\n \r\n
\r\n {quantity &&\r\n renderQuantity(\r\n quantity,\r\n callbacks,\r\n props,\r\n state,\r\n resources,\r\n quantityLimitsMessages,\r\n max,\r\n telemetryContent,\r\n unitOfMeasure\r\n )}\r\n {props.bulkPurchaseLink}\r\n {props.config.stockAvailableText}\r\n
\r\n
\r\n {props.config.displayStockAvailability && preferredStoreId && renderAvailabilityAtPreferredStore()}\r\n {inventoryLabel}\r\n {renderAddToCart(addToCart)}\r\n {findInStore && renderFindInStore(findInStore)}\r\n {addToWishlist && renderAddToWishlist(props, state, callbacks)}\r\n {productComparisonButton}\r\n {addToOrderTemplate && renderAddToOrderTemplate(props, state, callbacks)}\r\n {/* {findInStore?.productPickupOptionList ? (\r\n
{findInStore.productPickupOptionList}
\r\n ) : null} */}\r\n {_renderSocialShare(props.slots && props.slots.socialShare)}\r\n {/*
{props.resources.shopText}
*/}\r\n\r\n \r\n {shopSimilarLook && renderShopSimilarItem(shopSimilarLook)}\r\n {shopSimilarDescription && renderShopSimilarItem(shopSimilarDescription)}\r\n \r\n \r\n
{props.resources.descriptionText}
\r\n \r\n {productIngredient && productIngredient.TextValue !== '' && (\r\n \r\n )}\r\n\r\n {/* {description} */}\r\n
\r\n {ArrayExtensions.hasElements(props.slots.productSpecification) ? (\r\n {props.slots.productSpecification[0]}\r\n ) : null}\r\n
\r\n \r\n
\r\n
\r\n
\r\n );\r\n};\r\n\r\nexport default BuyboxView;\r\n","const binding = { modules: {}, dataActions: {} };\n\n const registerActionId = (actionPath) => {\n if (binding.dataActions[actionPath] &&\n binding.dataActions[actionPath].default &&\n binding.dataActions[actionPath].default.prototype &&\n binding.dataActions[actionPath].default.prototype.id) {\n binding.dataActions[binding.dataActions[actionPath].default.prototype.id] = binding.dataActions[actionPath];\n } else {\n Object.keys(binding.dataActions[actionPath] || {}).forEach(exportName => {\n if (binding.dataActions[actionPath][exportName] &&\n binding.dataActions[actionPath][exportName].prototype &&\n binding.dataActions[actionPath][exportName].prototype.Action) {\n binding.dataActions[binding.dataActions[actionPath][exportName].prototype.id] = binding.dataActions[actionPath][exportName];\n }\n })\n }\n };\n\n const registerSanitizedActionPath = (sanitizedActionPath, dataAction) => {\n if (process.env.NODE_ENV === 'development') {\n if (!dataAction.default) {\n throw new Error('Data action path does not have a default export');\n }\n if (!(dataAction.default.prototype.id && binding.dataActions[dataAction.default.prototype.id]) || !binding.dataActions[sanitizedActionPath]) {\n binding.dataActions[sanitizedActionPath] = dataAction;\n }\n } else {\n binding.dataActions[sanitizedActionPath] = dataAction;\n if (!binding.dataActions[sanitizedActionPath].default) {\n throw new Error('Data action path ' + sanitizedActionPath + ' does not have a default export');\n }\n binding.dataActions[sanitizedActionPath].default.prototype.RegistrationId = sanitizedActionPath;\n if (binding.dataActions[sanitizedActionPath].default.prototype.id) {\n binding.dataActions[binding.dataActions[sanitizedActionPath].default.prototype.id] = sanitizedActionPath;\n }\n }\n };\n \n\n (binding.modules['buybox'] = {\n c: () => require('@msdyn365-commerce-modules/buybox/dist/lib/modules/buybox/buybox'),\n $type: 'containerModule',\n da: [{name:'cart', path:'@msdyn365-commerce/global-state/dist/lib/data-actions/cart-state-data-action', runOn: 0},{name:'cartConfiguration', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-cart-configuration', runOn: 0},{name:'catalogs', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-catalogs', runOn: 0},{name:'channelDeliveryOptionConfig', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-channel-delivery-option-configuration', runOn: 0},{name:'customerInformation', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-customer', runOn: 0},{name:'deliveryOptions', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-delivery-options-for-selected-variant', runOn: 0},{name:'featureState', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-feature-state', runOn: 0},{name:'orderTemplates', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/order-templates/get-order-templates-preview', runOn: 1},{name:'product', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-selected-variant', runOn: 0},{name:'productAvailableQuantity', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-product-availabilities-for-selected-variant', runOn: 0},{name:'productDimensions', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-dimensions-for-selected-variant', runOn: 0},{name:'productPrice', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-price-for-selected-variant', runOn: 0},{name:'ratingsSummary', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-ratings-summary', runOn: 1},{name:'storeSelectorStateManager', path:'@msdyn365-commerce-modules/bopis-utilities/dist/lib/store-selector-state-manager/store-selector-state-manager-data-action', runOn: 1},{name:'wishlists', path:'@msdyn365-commerce-modules/retail-actions/dist/lib/get-wishlist-by-customer-id', runOn: 0}],\n \n iNM: true,\n ns: '@msdyn365-commerce-modules',\n n: 'buybox',\n p: 'buybox',\n \n pdp: '',\n \n \n md: 'node_modules/@msdyn365-commerce-modules/buybox/dist/lib/modules/buybox'\n });\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/bopis-utilities/dist/lib/store-selector-state-manager/store-selector-state-manager-data-action';\n let dataAction = require('@msdyn365-commerce-modules/bopis-utilities/dist/lib/store-selector-state-manager/store-selector-state-manager-data-action');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-cart-configuration';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-cart-configuration');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-catalogs';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-catalogs');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-channel-delivery-option-configuration';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-channel-delivery-option-configuration');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-customer';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-customer');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-delivery-options-for-selected-variant';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-delivery-options-for-selected-variant');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-dimensions-for-selected-variant';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-dimensions-for-selected-variant');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-feature-state';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-feature-state');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-price-for-selected-variant';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-price-for-selected-variant');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-product-availabilities-for-selected-variant';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-product-availabilities-for-selected-variant');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-ratings-summary';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-ratings-summary');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-selected-variant';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-selected-variant');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/get-wishlist-by-customer-id';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/get-wishlist-by-customer-id');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce-modules/retail-actions/dist/lib/order-templates/get-order-templates-preview';\n let dataAction = require('@msdyn365-commerce-modules/retail-actions/dist/lib/order-templates/get-order-templates-preview');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n {\n const sanitizedActionPath = '@msdyn365-commerce/global-state/dist/lib/data-actions/cart-state-data-action';\n let dataAction = require('@msdyn365-commerce/global-state/dist/lib/data-actions/cart-state-data-action');\n registerSanitizedActionPath(sanitizedActionPath, dataAction);\n }\n \n\n \n window.__bindings__ = window.__bindings__ || {};\n window.__bindings__.modules = {\n ...window.__bindings__.modules || {},\n ...binding.modules\n };\n \n window.__bindings__.dataActions = {\n ...window.__bindings__.dataActions || {},\n ...binding.dataActions\n };\n export const viewDictionary = {};\n viewDictionary['__local__|__local__|themes|newsunshine-b2c|views|buybox'] = {\n c: () => require('partner/themes/newsunshine-b2c/views/buybox.view.tsx'),\n cn: '__local__-__local__-buybox'\n };\nviewDictionary['__local__|__local__|themes|newsunshine|views|buybox'] = {\n c: () => require('partner/themes/newsunshine/views/buybox.view.tsx'),\n cn: '__local__-__local__-buybox'\n };\nviewDictionary['@msdyn365-commerce-modules|buybox|modules|buybox|buybox'] = {\n c: () => require('@msdyn365-commerce-modules/buybox/dist/lib/modules/buybox/buybox.view.js'),\n cn: '@msdyn365-commerce-modules-buybox-buybox'\n };\nviewDictionary['@msdyn365-commerce-modules|fabrikam-design-kit|modules|fabrikam|views|buybox'] = {\n c: () => require('@msdyn365-commerce-modules/fabrikam-design-kit/dist/lib/modules/fabrikam/views/buybox.view.js'),\n cn: '@msdyn365-commerce-modules-fabrikam-design-kit-buybox'\n };\nviewDictionary['@msdyn365-commerce-theme|adventureworks-theme-kit|modules|adventureworks|views|buybox'] = {\n c: () => require('@msdyn365-commerce-theme/adventureworks-theme-kit/dist/lib/modules/adventureworks/views/buybox.view.js'),\n cn: '@msdyn365-commerce-theme-adventureworks-theme-kit-buybox'\n };\nwindow.__bindings__ = window.__bindings__ || {};\nwindow.__bindings__.viewDictionary = {\n ...window.__bindings__.viewDictionary || {},\n ...viewDictionary\n };","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport MsDyn365, { IActionContext } from '@msdyn365-commerce/core';\nimport { action, computed, observable } from 'mobx';\n\nimport {\n IListMapViewState,\n ILoadMapApiInput,\n IStoreInfo,\n IStoreSelectionStateContext,\n IStoreSelectorLocation,\n IStoreSelectorStateManager\n} from './i-store-selection-state-manager';\n\n/**\n * Abstract instance of IStoreSelectorStateManager with base implementation\n * of everything except the geoLocate function.\n */\nexport abstract class BaseStoreSelectorStateManager implements IStoreSelectorStateManager {\n @computed public get isDialogOpen(): Readonly {\n return this._context !== undefined;\n }\n\n @computed public get context(): Readonly {\n return this._context;\n }\n\n @observable public isMapApiLoaded?: boolean;\n\n @observable public selectedStoreLocationId?: string;\n\n @observable public preferredStore?: IStoreInfo;\n\n @observable public listMapViewState: IListMapViewState = { displayList: true, displayMap: false };\n\n @observable public isMapModuleLoaded?: boolean;\n\n @observable public lastInlineShownStoreInfo?: IStoreInfo;\n\n @observable protected _context?: IStoreSelectionStateContext;\n\n private readonly preferredStoreLocalStorageKey: string = '_msdyn365__preferredStore_';\n\n constructor() {\n this.isMapModuleLoaded = false;\n const value = this._readFromToCookie(this.preferredStoreLocalStorageKey);\n try {\n const storeInfo: IStoreInfo | undefined = value ? JSON.parse(value) : undefined;\n if (storeInfo) {\n this.preferredStore = storeInfo;\n }\n } catch {\n this.preferredStore = undefined;\n }\n }\n\n public abstract geoLocate(searchTerm: string, actionContext: IActionContext): Promise;\n\n public abstract loadMapApi(input: ILoadMapApiInput): Promise;\n\n @action\n public async toggleListMapViewState(): Promise {\n this.listMapViewState = {\n displayList: !this.listMapViewState.displayList,\n displayMap: !this.listMapViewState.displayMap\n };\n }\n\n @action\n public async setMapModuleLoaded(input: boolean): Promise {\n this.isMapModuleLoaded = input;\n }\n\n @action\n public async setOrgUnitStoreInformation(input: IStoreSelectionStateContext): Promise {\n this._context = input;\n }\n\n @action\n public async setSelectedStoreLocationId(storeId: string | undefined): Promise {\n this.selectedStoreLocationId = storeId;\n }\n\n @action\n public async setPreferredStoreLocation(\n storeId?: string,\n storeName?: string | undefined,\n writeToCookie: boolean = false,\n latitude?: number,\n longitude?: number\n ): Promise {\n const storeInfo: IStoreInfo = { StoreId: storeId, StoreName: storeName, Latitude: latitude, Longitude: longitude };\n this.preferredStore = storeInfo;\n if (writeToCookie) {\n this._writeToCookie(this.preferredStoreLocalStorageKey, JSON.stringify(storeInfo));\n }\n }\n\n @action\n public async setLastInlineStoreInfo(latitude?: number, longitude?: number): Promise {\n const storeInfo: IStoreInfo = { StoreId: '', StoreName: '', Latitude: latitude, Longitude: longitude };\n this.lastInlineShownStoreInfo = storeInfo;\n }\n\n @action\n public async clearPreferredStore(writeToCookie: boolean): Promise {\n this.preferredStore = undefined;\n if (writeToCookie) {\n this._removeCookie(this.preferredStoreLocalStorageKey);\n }\n }\n\n @action\n public async openDialog(input: IStoreSelectionStateContext): Promise {\n if (this._context && this._context.id === input.id) {\n throw new Error('Dialog is already opened');\n }\n\n this._context = input;\n }\n\n @action\n public async closeDialog(): Promise {\n this._context = undefined;\n }\n\n private _removeCookie(key: string): void {\n if (!key) {\n return;\n }\n if (MsDyn365.isBrowser) {\n const storage = window.localStorage;\n storage.removeItem(key);\n }\n }\n\n private _writeToCookie(key: string, value: string | undefined): void {\n if (!key || !value) {\n return;\n }\n if (MsDyn365.isBrowser) {\n const storage = window.localStorage;\n storage.setItem(key, value);\n }\n }\n\n private _readFromToCookie(key: string): string | undefined {\n if (!key) {\n return undefined;\n }\n if (MsDyn365.isBrowser) {\n const storage = window.localStorage;\n const cookieValue = storage.getItem(key);\n if (cookieValue) {\n return cookieValue;\n }\n }\n\n return undefined;\n }\n}\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { IActionContext } from '@msdyn365-commerce/core';\nimport { StringExtensions } from '@msdyn365-commerce-modules/retail-actions';\nimport { action } from 'mobx';\n\nimport { BaseStoreSelectorStateManager } from './base-store-selector-state-manager';\nimport { ILoadMapApiInput, IStoreSelectorLocation } from './i-store-selection-state-manager';\nimport { IMapWindow, MapLocationsResult } from './models/map-data';\n\ndeclare const window: IMapWindow;\n\n/**\n * Instance of IStoreSelectorStateManager manager that uses Map service\n * for geo location.\n */\nexport class MapStoreSelectorStateManager extends BaseStoreSelectorStateManager {\n private readonly SERVICE_ENDPOINT: string = 'https://dev.virtualearth.net/REST/v1/';\n\n private readonly MAP_API_ENDPOINT: string = 'https://www.bing.com/api/maps/mapcontrol?callback=mapAPIReady';\n\n @action\n public async geoLocate(searchTerm: string, actionContext: IActionContext): Promise {\n if (\n !searchTerm ||\n !actionContext.requestContext.channel ||\n !actionContext.requestContext.channel.BingMapsApiKey ||\n !actionContext.requestContext.channel.BingMapsEnabled\n ) {\n return undefined;\n }\n\n let searchContent: string = searchTerm;\n\n const jsonp = `mapSearchCallback_${crypto.getRandomValues(new Uint32Array(1))[0]}`;\n\n if (actionContext.requestContext.channel.ChannelCountryRegionISOCode) {\n searchContent = `${searchTerm.trim()} ${actionContext.requestContext.channel.ChannelCountryRegionISOCode}`;\n }\n\n const query = encodeURI(searchContent);\n const key = encodeURI(actionContext.requestContext.channel.BingMapsApiKey);\n\n const geolocationApiUrl =\n actionContext.requestContext.app &&\n actionContext.requestContext.app.config &&\n actionContext.requestContext.app.config.geolocationApiUrl;\n const requestUrl = `${\n geolocationApiUrl ? geolocationApiUrl : this.SERVICE_ENDPOINT\n }/Locations?query=${query}&key=${key}&jsonp=${jsonp}`;\n\n return new Promise(resolve => {\n const script = document.createElement('script');\n script.setAttribute('type', 'text/javascript');\n script.setAttribute('src', requestUrl);\n\n window[jsonp] = (data: MapLocationsResult) => {\n delete window[jsonp];\n script.remove();\n\n if (data && data.resourceSets && data.resourceSets.length > 0 && data.resourceSets[0].resources.length > 0) {\n resolve({\n latitude: data.resourceSets[0].resources[0].point.coordinates[0],\n longitude: data.resourceSets[0].resources[0].point.coordinates[1]\n });\n }\n\n resolve(undefined);\n };\n\n document.body.appendChild(script);\n });\n }\n\n @action\n public async loadMapApi(input: ILoadMapApiInput): Promise {\n if (StringExtensions.isNullOrEmpty(input.key)) {\n return Promise.resolve();\n }\n\n const isScriptAlreadyLoaded = !!document?.getElementById('msdyn_map-api-script');\n\n if (isScriptAlreadyLoaded) {\n if (window) {\n const currentWindowAPI = window.mapAPIReady;\n window.mapAPIReady = () => {\n if (currentWindowAPI) {\n currentWindowAPI();\n }\n this.isMapApiLoaded = true;\n };\n }\n // Prevents from loading multiple script into the body\n return Promise.resolve();\n }\n\n const url = `${this.MAP_API_ENDPOINT}${input.key ? `&key=${input.key}` : ''}${input.lang ? `&setLang=${input.lang}` : ''}${\n input.market ? `&setMkt=${input.market}` : ''\n }`;\n\n return new Promise((resolve, reject) => {\n const script = document?.createElement('script');\n script.type = 'text/javascript';\n script.async = true;\n script.defer = true;\n script.src = url;\n script.id = 'msdyn_map-api-script';\n if (window) {\n window.mapAPIReady = () => {\n this.isMapApiLoaded = true;\n resolve();\n };\n }\n script.addEventListener('error', (error: string | Event) => {\n reject(error);\n });\n document?.body?.appendChild(script);\n });\n }\n}\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { createObservableDataAction, IAction, IActionInput, IAny, ICreateActionContext, IGeneric } from '@msdyn365-commerce/core';\nimport { GenericInput, getGenericAction } from '@msdyn365-commerce-modules/retail-actions';\n\nimport { IStoreSelectorStateManager } from './i-store-selection-state-manager';\nimport { MapStoreSelectorStateManager } from './map-store-selector-state-manager';\n\nexport function createStoreSelectorStateInput(result: IStoreSelectorStateManager): GenericInput {\n return new GenericInput('mapSSSM', result, 'IStoreSelectorStateManager');\n}\n\nconst createStoreSelectorStateInputInternal = (inputData: ICreateActionContext>): IActionInput => {\n return createStoreSelectorStateInput(new MapStoreSelectorStateManager());\n};\n\nexport const getGenericActionDataAction = createObservableDataAction({\n action: >getGenericAction,\n input: createStoreSelectorStateInputInternal\n});\n\nexport default getGenericActionDataAction;\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport {\n IBuyboxAddToCartViewProps,\n IBuyboxAddToOrderTemplateViewProps,\n IBuyboxAddToWishlistViewProps,\n IBuyboxCallbacks,\n IBuyboxData,\n IBuyboxFindInStoreViewProps,\n IBuyboxKeyInPriceViewProps,\n IBuyboxProductConfigureDropdownViewProps,\n IBuyboxProductConfigureViewProps,\n IBuyboxProductQuantityViewProps,\n IBuyboxProps,\n IBuyboxShopSimilarLookViewProps,\n IBuyboxState,\n IBuyboxViewProps\n} from '@msdyn365-commerce-modules/buybox';\nimport { IncrementalQuantity, ITelemetryContent, Module, Node } from '@msdyn365-commerce-modules/utilities';\nimport * as React from 'react';\n\nimport {\n IBuyboxProps as IBuyboxExtentionProps,\n IBuyboxResources as IBuyboxExtentionResources\n} from '../definition-extensions/buybox.ext.props.autogenerated';\n\nconst BuyboxView: React.FC> = props => {\n const {\n ModuleProps,\n MediaGalleryContainerProps,\n ProductInfoContainerProps,\n addToCart,\n addToOrderTemplate,\n addToWishlist,\n telemetryContent,\n configure,\n description,\n findInStore,\n quantity,\n price,\n title,\n rating,\n callbacks,\n state,\n resources,\n inventoryLabel,\n shopSimilarLook,\n keyInPrice,\n quantityLimitsMessages,\n min,\n max,\n applyDefaultOrderSettings,\n shopSimilarDescription,\n unitOfMeasure\n } = props;\n\n return (\n \n {props.mediaGallery}\n \n {title}\n {price}\n {unitOfMeasure}\n {props.bulkPurchaseLink}\n {description}\n {_renderTextBlock(props.slots.textBlocks)}\n {rating}\n {configure && _renderConfigure(configure)}\n {keyInPrice && _renderKeyInPrice(keyInPrice)}\n {quantity &&\n _renderQuantity(\n quantity,\n callbacks,\n props,\n state,\n resources,\n quantityLimitsMessages,\n min,\n max,\n applyDefaultOrderSettings,\n telemetryContent\n )}\n {inventoryLabel}\n {_renderCartAndActions(addToCart, addToOrderTemplate, addToWishlist)}\n {findInStore && _renderFindInStore(findInStore)}\n {_renderSocialShare(props.slots && props.slots.socialShare)}\n {shopSimilarLook && _renderShopSimilarItem(shopSimilarLook)}\n {shopSimilarDescription && _renderShopSimilarItem(shopSimilarDescription)}\n \n \n );\n};\n\nconst _renderTextBlock = (textBlocks: React.ReactNode[]): JSX.Element | undefined => {\n if (!textBlocks || textBlocks.length === 0) {\n return undefined;\n }\n\n return <>{textBlocks[0]};\n};\n\nconst _renderSocialShare = (socialShare: React.ReactNode[]): JSX.Element | undefined => {\n if (!socialShare || socialShare.length === 0) {\n return undefined;\n }\n\n return <>{socialShare[0]};\n};\n\nconst _renderCartAndActions = (\n addToCart?: IBuyboxAddToCartViewProps,\n addToOrderTemplate?: IBuyboxAddToOrderTemplateViewProps,\n addToWishlist?: IBuyboxAddToWishlistViewProps\n): JSX.Element | undefined => {\n if (!addToCart && !addToWishlist) {\n return undefined;\n }\n\n return (\n
\n {addToCart && addToCart.errorBlock}\n {addToOrderTemplate && addToOrderTemplate.errorBlock}\n {addToWishlist && addToWishlist.errorBlock}\n
\n {addToCart && addToCart.button}\n {addToOrderTemplate && addToOrderTemplate.button}\n {addToWishlist && addToWishlist.button}\n
\n
\n );\n};\n\nconst _renderConfigure = (configure: IBuyboxProductConfigureViewProps): JSX.Element => {\n const { ContainerProps, dropdowns } = configure;\n\n return {dropdowns.map(_renderConfigureDropdown)};\n};\n\nconst _renderConfigureDropdown = (dropdown: IBuyboxProductConfigureDropdownViewProps): JSX.Element => {\n const { ContainerProps, LabelContainerProps, heading, errors, select } = dropdown;\n\n return (\n \n \n {heading}\n {errors}\n \n {select}\n \n );\n};\n\nconst _renderFindInStore = (findInStore: IBuyboxFindInStoreViewProps): JSX.Element => {\n const { ContainerProps, storeSelector, heading, description, errors, button, modal, productPickupOptionList } = findInStore;\n\n return (\n \n {storeSelector}\n {heading}\n {productPickupOptionList}\n {description}\n {errors}\n {button}\n {modal}\n \n );\n};\n\n/**\n * On Change function.\n * @param callbacks -Callbacks.\n * @returns Update quantity.\n */\nconst onChangeHandler = (callbacks: IBuyboxCallbacks) => (newValue: number): boolean => {\n if (callbacks.updateQuantity) {\n return callbacks.updateQuantity(newValue);\n }\n return true;\n};\n\nconst _renderQuantity = (\n quantityComponent: IBuyboxProductQuantityViewProps,\n callbacks: IBuyboxCallbacks,\n props: IBuyboxProps,\n state: IBuyboxState,\n extentionResources: IBuyboxExtentionResources,\n quantityLimitsMessages: React.ReactNode,\n min: number | undefined,\n max: number | undefined,\n applyDefaultOrderSettings?: boolean,\n telemetryContent?: ITelemetryContent\n): JSX.Element => {\n const { ContainerProps, LabelContainerProps, heading, errors } = quantityComponent;\n\n const { resources } = props;\n\n const { quantity } = state;\n\n return (\n \n \n {heading}\n {errors}\n \n\n \n {quantityLimitsMessages}\n \n );\n};\n\nconst _renderKeyInPrice = (keyInPrice: IBuyboxKeyInPriceViewProps): JSX.Element => {\n const { ContainerProps, LabelContainerProps, heading, input } = keyInPrice;\n\n return (\n \n {heading}\n {input}\n \n );\n};\n\nconst _renderShopSimilarItem = (shopSimilarItem: IBuyboxShopSimilarLookViewProps): JSX.Element => {\n const { ContainerProps, errors, input } = shopSimilarItem;\n\n return (\n \n {errors}\n {input}\n \n );\n};\n\nexport default BuyboxView;\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport {\n AddToOrderTemplateComponent,\n IAddToOrderTemplateDialogResources,\n IDuplicateItemsWhenAddingToOrderTemplateDialogResources,\n IItemAddedToOrderTemplateDialogResources,\n IOrderTemplateActionErrorResult,\n IOrderTemplateNameDialogResources\n} from '@msdyn365-commerce/components';\nimport { SimpleProduct } from '@msdyn365-commerce/retail-proxy';\nimport {\n getConfigureErrors,\n IBuyboxCallbacks,\n IBuyboxCommonResources,\n IBuyboxData,\n IBuyboxState,\n IBuyboxViewProps\n} from '@msdyn365-commerce-modules/buybox';\nimport * as React from 'react';\n\nimport { IBuyboxProps as IBuyboxExtentionProps } from '../../definition-extensions/buybox.ext.props.autogenerated';\n\n/**\n * To generate AddToOrderTemplateDialog resources.\n * @param resources - The resources.\n * @returns -- Returns the list of AddToOrderTemplateDialog resources..\n */\nfunction generateAddToOrderTemplateDialogResources(resources: IBuyboxCommonResources): IAddToOrderTemplateDialogResources {\n return {\n addToOrderTemplateHeader: resources.addToOrderTemplateHeader,\n\n noOrderTemplatesMessage: resources.noOrderTemplatesMessage,\n noOrderTemplatesDescription: resources.noOrderTemplatesDescription,\n\n createAnOrderTemplateButtonText: resources.createAnOrderTemplateButtonText,\n createNewOrderTemplateButtonText: resources.createNewOrderTemplateButtonText,\n cancelOrderTemplateCreationButtonText: resources.cancelOrderTemplateCreationButtonText,\n\n selectTemplatesText: resources.selectTemplatesText,\n addToTemplateButtonText: resources.addToTemplateButtonText,\n lineItemsText: resources.lineItemsText\n };\n}\n\n/**\n * To generate OrderTemplateNameDialog resources.\n * @param resources - The resources.\n * @returns -- Returns the list of OrderTemplateNameDialog resources..\n */\nfunction generateOrderTemplateNameDialogResources(resources: IBuyboxCommonResources): IOrderTemplateNameDialogResources {\n return {\n orderTemplateHeaderLabel: resources.createOrderTemplateHeader,\n orderTemplateTitleLabel: resources.orderTemplateTitle,\n orderTemplateNameAriaLabel: resources.orderTemplateNameAriaLabel,\n orderTemplateDescription: resources.createOrderTemplateDescription,\n\n defaultOrderTemplateName: resources.defaultOrderTemplateName,\n\n orderTemplateButtonLabel: resources.createOrderTemplateButtonText,\n orderTemplateCancelButtonLabel: resources.cancelNewOrderTemplateCreationButtonText\n };\n}\n\n/**\n * To generate ItemAddedToOrderTemplateDialog resources.\n * @param resources - The resources.\n * @returns -- Returns the list of ItemAddedToOrderTemplateDialog resources..\n */\nfunction generateItemAddedToOrderTemplateDialogResources(resources: IBuyboxCommonResources): IItemAddedToOrderTemplateDialogResources {\n return {\n viewOrderTemplateButtonText: resources.viewOrderTemplateButtonText,\n continueShoppingButtonText: resources.continueShoppingButtonText,\n itemAddedToOrderTemplateHeaderItemOneText: resources.itemAddedToOrderTemplateHeaderItemOneText,\n itemAddedToOrderTemplateHeaderItemFormatText: resources.itemAddedToOrderTemplateHeaderItemFormatText,\n itemAddedToOrderTemplateHeaderMessageText: resources.itemAddedToOrderTemplateHeaderMessageText,\n freePriceText: resources.priceFree,\n originalPriceText: resources.originalPriceText,\n currentPriceText: resources.currentPriceText\n };\n}\n\n/**\n * To generate DuplicateItemsWhenAddingToOrderTemplateDialog resources.\n * @param resources - The resources.\n * @returns -- Returns the list of DuplicateItemsWhenAddingToOrderTemplateDialog resources..\n */\nfunction generateDuplicateItemsWhenAddingToOrderTemplateDialogResources(\n resources: IBuyboxCommonResources\n): IDuplicateItemsWhenAddingToOrderTemplateDialogResources {\n return {\n duplicatedProductsHeader: resources.duplicatedProductsHeader,\n duplicatedProductsDescription: resources.duplicatedProductsDescription,\n updateQuantityButtonText: resources.updateQuantityButtonText,\n cancelDuplicateItemsButtonText: resources.cancelDuplicateItemsButtonText\n };\n}\n\n/**\n * Add to wishlist failed function.\n * @param callbacks -Buybox callbacks.\n * @param resources -Buybox resources.\n * @param product -Simple product.\n * @returns Update error state.\n */\nconst onAddToOrderTemplateFailed = (callbacks: IBuyboxCallbacks, resources: IBuyboxCommonResources, product: SimpleProduct | undefined) => (\n result: IOrderTemplateActionErrorResult\n) => {\n callbacks.updateErrorState({\n errorHost: 'ORDER_TEMPLATE',\n configureErrors:\n result.status === 'MISSING_DIMENSION' ? getConfigureErrors(result.missingDimensions, resources, product?.IsGiftCard) : {}\n });\n};\n\n/**\n * RenderAddToOrderTemplateButton.\n * @param props - Buybox view props.\n * @param state - Buybox state.\n * @param callbacks - Buybox callbacks.\n * @param product - Product data.\n * @returns -- Returns JSX element.\n */\nexport const renderAddToOrderTemplateButton = (\n props: IBuyboxViewProps & IBuyboxExtentionProps,\n state: IBuyboxState,\n callbacks: IBuyboxCallbacks,\n product: SimpleProduct\n): React.ReactNode => {\n const {\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from module file.\n id,\n typeName,\n context,\n data: {\n orderTemplates: { result: orderTemplates },\n customerInformation: { result: customerInformation }\n },\n resources,\n config\n } = props;\n\n const { quantity } = state;\n\n const isShowButtonText = true;\n const isMultipleCatalogsFeatureEnabled = props.isChannelMultipleCatalogsFeatureEnabled || false;\n return (\n orderTemplates && (\n \n )\n );\n};\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { AddToWishlistComponent, IWishlistActionErrorResult } from '@msdyn365-commerce/components';\nimport { format, ItemAvailability, SimpleProduct } from '@msdyn365-commerce/retail-proxy';\nimport { IStoreInfo } from '@msdyn365-commerce-modules/bopis-utilities';\nimport {\n getConfigureErrors,\n IBuyboxAddToCartViewProps,\n IBuyboxCallbacks,\n IBuyboxCommonResources,\n IBuyboxData,\n IBuyboxFindInStoreViewProps,\n IBuyboxKeyInPriceViewProps,\n IBuyboxProductConfigureDropdownViewProps,\n IBuyboxProductConfigureViewProps,\n IBuyboxProductQuantityViewProps,\n IBuyboxResources as IBuyboxExtentionResources,\n IBuyboxShopSimilarLookViewProps,\n IBuyboxState,\n IBuyboxViewProps\n} from '@msdyn365-commerce-modules/buybox';\nimport {\n ArrayExtensions,\n getFullAvailableInventoryNearby,\n GetFullAvailableInventoryNearbyInput,\n IFullOrgUnitAvailability\n} from '@msdyn365-commerce-modules/retail-actions';\nimport { IncrementalQuantity, INodeProps, ITelemetryContent, Module, Node } from '@msdyn365-commerce-modules/utilities';\nimport { reaction } from 'mobx';\nimport * as React from 'react';\n\nimport { IBuyboxProps as IBuyboxExtentionProps, IBuyboxProps } from '../definition-extensions/buybox.ext.props.autogenerated';\nimport { renderAddToOrderTemplateButton } from './components/buybox-add-to-order-template';\n\n/**\n * BuyBoxConstants enum.\n */\nexport enum BuyBoxConstants {\n zero = 0\n}\n\n/**\n * On Change function.\n * @param callbacks -Callbacks.\n * @returns Update quantity.\n */\nconst onChangeHandler = (callbacks: IBuyboxCallbacks) => (newValue: number): boolean => {\n if (callbacks.updateQuantity) {\n return callbacks.updateQuantity(newValue);\n }\n return true;\n};\n\n/**\n * RenderQuantity.\n * @param quantityComponent - QuantityComponent.\n * @param callbacks - Callbacks.\n * @param props - Props.\n * @param state - State.\n * @param extentionResources - ExtentionResources.\n * @param quantityLimitsMessages - QuantityLimitsMessages.\n * @param max - Max.\n * @param telemetryContent - TelemetryContent.\n * @param unitOfMeasure - Unit Of Measure.\n * @returns -- Returns.\n */\nconst renderQuantity = (\n quantityComponent: IBuyboxProductQuantityViewProps,\n callbacks: IBuyboxCallbacks,\n props: IBuyboxProps,\n state: IBuyboxState,\n extentionResources: IBuyboxExtentionResources,\n quantityLimitsMessages: React.ReactNode,\n\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n min: number | undefined,\n max: number | undefined,\n applyDefaultOrderSettings?: boolean,\n telemetryContent?: ITelemetryContent,\n unitOfMeasure?: React.ReactNode\n): JSX.Element => {\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n const { ContainerProps, LabelContainerProps, heading, errors } = quantityComponent;\n\n const { resources } = props;\n\n const { quantity } = state;\n\n return (\n \n \n {heading}\n {errors}\n \n\n \n {unitOfMeasure}\n {quantityLimitsMessages}\n \n );\n};\n\n/**\n * Render key in price function.\n * @param keyInPrice - KeyInPrice.\n * @returns -- Returns.\n */\nconst renderKeyInPrice = (keyInPrice: IBuyboxKeyInPriceViewProps): JSX.Element => {\n const { ContainerProps, LabelContainerProps, heading, input } = keyInPrice;\n\n return (\n \n {heading}\n {input}\n \n );\n};\n\n/**\n * RenderAddToCart.\n * @param addToCart - AddToCart.\n * @returns -- Returns.\n */\nconst renderAddToCart = (addToCart: IBuyboxAddToCartViewProps): JSX.Element => {\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n const { ContainerProps, errorBlock, button } = addToCart;\n\n return (\n \n {errorBlock}\n {button}\n \n );\n};\n\n/**\n * RenderFindInStore.\n * @param findInStore - FindInStore.\n * @returns -- Returns.\n */\nconst renderFindInStore = (findInStore: IBuyboxFindInStoreViewProps): JSX.Element => {\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n const { ContainerProps, storeSelector, heading, description, errors, button, modal, productPickupOptionList } = findInStore;\n\n return (\n \n {storeSelector}\n {heading}\n {productPickupOptionList}\n {description}\n {errors}\n {button}\n {modal}\n \n );\n};\n\n/**\n * RenderAddToOrderTemplate.\n * @param props - Buybox view props.\n * @param state - Buybox state.\n * @param callbacks - Buybox callbacks.\n * @returns -- Returns.\n */\nconst renderAddToOrderTemplate = (\n props: IBuyboxViewProps & IBuyboxExtentionProps,\n state: IBuyboxState,\n callbacks: IBuyboxCallbacks\n): JSX.Element | null => {\n const product = props.data.product.result;\n if (!props.addToOrderTemplate || !product) {\n return null;\n }\n\n const orderTemplateButton = renderAddToOrderTemplateButton(props, state, callbacks, product);\n\n return (\n \n {props.addToOrderTemplate.errorBlock}\n {orderTemplateButton}\n \n );\n};\n\n/**\n * Add to wishlist failed function.\n * @param callbacks -Buybox callbacks.\n * @param resources -Buybox resources.\n * @param product -Simple product.\n * @returns Update error state.\n */\nconst onAddToWishlistFailed = (callbacks: IBuyboxCallbacks, resources: IBuyboxCommonResources, product: SimpleProduct | undefined) => (\n result: IWishlistActionErrorResult\n) => {\n callbacks.updateErrorState({\n errorHost: 'WISHLIST',\n configureErrors:\n result.status === 'MISSINGDIMENSION' ? getConfigureErrors(result.missingDimensions, resources, product?.IsGiftCard) : {}\n });\n};\n\n/**\n * RenderAddToWishlist.\n * @param props - Buybox view props.\n * @param state - Buybox state.\n * @param callbacks - Buybox callbacks.\n * @param product - Product data.\n * @returns -- Returns.\n */\nconst renderAddtoWishlistButton = (\n props: IBuyboxViewProps & IBuyboxExtentionProps,\n state: IBuyboxState,\n callbacks: IBuyboxCallbacks,\n product: SimpleProduct\n): React.ReactNode => {\n const { context, resources } = props;\n const wishlists = props.data.wishlists.result;\n const isShowWishlitButtonText = true;\n return (\n \n );\n};\n\n/**\n * RenderAddToWishlist.\n * @param props - Buybox viewprops.\n * @param state - Buybox state.\n * @param callbacks - Buybox callbacks.\n * @returns -- Returns.\n */\nconst renderAddToWishlist = (\n props: IBuyboxViewProps & IBuyboxExtentionProps,\n state: IBuyboxState,\n callbacks: IBuyboxCallbacks\n): JSX.Element | null => {\n const product = props.data.product.result;\n if (!props.addToWishlist || !product) {\n return null;\n }\n\n if (!props.config.enableWishlist) {\n return null;\n }\n\n const wishlistButton = renderAddtoWishlistButton(props, state, callbacks, product);\n return (\n \n {props.addToWishlist.errorBlock}\n {wishlistButton}\n \n );\n};\n\n/**\n * RRenderShopSimilarItem.\n * @param shopSimilarItem - ShopSimilarItem.\n * @returns -- Returns.\n */\nconst renderShopSimilarItem = (shopSimilarItem: IBuyboxShopSimilarLookViewProps): JSX.Element => {\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n const { ContainerProps, errors, input } = shopSimilarItem;\n\n return (\n \n {errors}\n {input}\n \n );\n};\n\n/**\n * RenderSocialShare.\n * @param socialShare - Social share react node array.\n * @returns -- Returns.\n */\nconst _renderSocialShare = (socialShare: React.ReactNode[]): JSX.Element | undefined => {\n if (!socialShare || socialShare.length === 0) {\n return undefined;\n }\n\n return <>{socialShare[0]};\n};\n\n/**\n * RenderConfigureDropdown.\n * @param dropdown - Buybox product configure dropdown view props.\n * @returns -- Returns JSX.Element.\n */\nconst renderConfigureDropdown = (dropdown: IBuyboxProductConfigureDropdownViewProps): JSX.Element => {\n const { ContainerProps, LabelContainerProps, heading, errors, select } = dropdown;\n\n return (\n \n {heading}\n {select}\n {errors}\n \n );\n};\n\n/**\n * RenderConfigure.\n * @param configure - Buybox product configure view props.\n * @returns -- Returns JSX.Element.\n */\nconst renderConfigure = (configure: IBuyboxProductConfigureViewProps): JSX.Element => {\n const { ContainerProps, dropdowns } = configure;\n\n return {dropdowns.map(renderConfigureDropdown)};\n};\n\n/**\n * BuyboxView.\n * @param props - Props.\n * @returns -- Returns.\n */\nconst BuyboxView: React.FC> = props => {\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n const {\n ModuleProps,\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n MediaGalleryContainerProps,\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n ProductInfoContainerProps,\n addToCart,\n addToOrderTemplate,\n addToWishlist,\n productComparisonButton,\n configure,\n description,\n findInStore,\n quantity,\n price,\n title,\n rating,\n inventoryLabel,\n shopSimilarLook,\n keyInPrice,\n shopSimilarDescription,\n min,\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Dependency from Buybox.tsx file\n max,\n applyDefaultOrderSettings,\n unitOfMeasure,\n callbacks,\n state,\n resources,\n quantityLimitsMessages,\n telemetryContent,\n app: { config: appConfig },\n catalogs\n } = props;\n let skuText: string = props.resources.skuText;\n skuText += props.data.product.result?.ItemId;\n const preferredStoreInfo: IStoreInfo | undefined = props.data.storeSelectorStateManager.result?.preferredStore;\n const preferredStoreId = preferredStoreInfo?.StoreId ? preferredStoreInfo.StoreId : '';\n const preferredStoreName = preferredStoreInfo?.StoreName ? preferredStoreInfo.StoreName : '';\n\n const [availability, setAvailability] = React.useState('');\n const [isStoreChange, setIsStoreChange] = React.useState(false);\n\n /**\n * GetStockInventoryLabel.\n * @param availabilityWithHours - Stock availability with hours.\n * @returns -- Returns.\n */\n const getStockInventoryLabel = (availabilityWithHours: IFullOrgUnitAvailability | undefined): string | undefined => {\n if (availabilityWithHours && ArrayExtensions.hasElements(availabilityWithHours.ProductInventoryInformation)) {\n for (const productInventoryInformation of availabilityWithHours.ProductInventoryInformation) {\n if (\n availabilityWithHours.OrgUnitAvailability?.OrgUnitLocation?.InventoryLocationId ===\n productInventoryInformation.InventLocationId\n ) {\n return productInventoryInformation.StockLevelLabel;\n }\n }\n }\n\n return undefined;\n };\n\n const getInventory = React.useCallback(async () => {\n const input = new GetFullAvailableInventoryNearbyInput(\n props.data.product.result?.RecordId,\n BuyBoxConstants.zero,\n BuyBoxConstants.zero,\n BuyBoxConstants.zero,\n BuyBoxConstants.zero,\n true\n );\n\n /**\n * IsProductInStock.\n * @param itemAvailabilities - Item availability array.\n * @returns -- Returns.\n */\n const isProductInStock = (itemAvailabilities: ItemAvailability[] | undefined): boolean => {\n if (!appConfig.enableStockCheck) {\n return true;\n }\n\n if (ArrayExtensions.hasElements(itemAvailabilities)) {\n return itemAvailabilities[BuyBoxConstants.zero].AvailableQuantity! > BuyBoxConstants.zero;\n }\n\n return false;\n };\n\n await getFullAvailableInventoryNearby(input, props.context.actionContext)\n .catch((error: Error) => {\n props.telemetry.error(error.message);\n })\n .then(response => {\n if (response && ArrayExtensions.hasElements(response)) {\n const isPreferredStore = (value: IFullOrgUnitAvailability) =>\n value.OrgUnitAvailability?.OrgUnitLocation?.OrgUnitNumber === preferredStoreId;\n const filteredFullOrgUnitAvailability = response.filter(isPreferredStore);\n const preferredStoreAvailability = ArrayExtensions.hasElements(filteredFullOrgUnitAvailability)\n ? filteredFullOrgUnitAvailability[BuyBoxConstants.zero]\n : undefined;\n const stockStatusLabel: string | undefined = getStockInventoryLabel(preferredStoreAvailability);\n const isInStock = isProductInStock(preferredStoreAvailability?.OrgUnitAvailability?.ItemAvailabilities);\n const resourceLabel = isInStock ? props.resources.inStockText : props.resources.outOfStockText;\n const stockText: string | undefined = stockStatusLabel ? stockStatusLabel : resourceLabel;\n const preferredStoreAvailabilityText = `${format(\n props.resources.availabilityAtPreferredStoreText,\n preferredStoreName\n )} ${stockText}`;\n setAvailability(preferredStoreAvailabilityText);\n }\n });\n\n setIsStoreChange(false);\n }, [\n props.data.product.result?.RecordId,\n appConfig.enableStockCheck,\n preferredStoreId,\n preferredStoreName,\n props.context.actionContext,\n props.resources.availabilityAtPreferredStoreText,\n props.resources.inStockText,\n props.resources.outOfStockText,\n props.telemetry\n ]);\n\n React.useEffect(() => {\n if (props.config.displayStockAvailability) {\n getInventory().catch((error: Error) => {\n props.telemetry.error(error.message);\n });\n }\n }, [getInventory, isStoreChange, props.telemetry, props.config.displayStockAvailability]);\n\n reaction(\n () => props.data.storeSelectorStateManager.result?.selectedStoreLocationId,\n () => {\n setIsStoreChange(true);\n }\n );\n\n /**\n * RenderAvailabiltyAtPreferredStore.\n * @returns -- Returns.\n */\n const renderAvailabilityAtPreferredStore = (): JSX.Element | undefined => {\n const hasProductDimensions = ArrayExtensions.hasElements(props.data.product.result?.Dimensions);\n if (hasProductDimensions && props.data.product.result?.MasterProductId === undefined) {\n return undefined;\n }\n const containerProps: INodeProps = {\n className: 'ms-buybox__preferred-store-availability',\n tag: 'span'\n };\n\n return {availability};\n };\n return (\n \n {props.mediaGallery}\n \n {catalogs && catalogs[0].Name}\n {title}\n \n
{skuText}
\n {rating}\n
\n \n
{props.resources.priceText}
\n {price}\n
\n {configure && renderConfigure(configure)}\n {keyInPrice && renderKeyInPrice(keyInPrice)}\n \n
\n {quantity &&\n renderQuantity(\n quantity,\n callbacks,\n props,\n state,\n resources,\n quantityLimitsMessages,\n min,\n max,\n applyDefaultOrderSettings,\n telemetryContent,\n unitOfMeasure\n )}\n {props.bulkPurchaseLink}\n
\n
\n {props.config.displayStockAvailability && preferredStoreId && renderAvailabilityAtPreferredStore()}\n {inventoryLabel}\n {renderAddToCart(addToCart)}\n {findInStore && renderFindInStore(findInStore)}\n {addToWishlist && renderAddToWishlist(props, state, callbacks)}\n {productComparisonButton}\n {addToOrderTemplate && renderAddToOrderTemplate(props, state, callbacks)}\n {findInStore?.productPickupOptionList ? (\n
{findInStore.productPickupOptionList}
\n ) : null}\n {_renderSocialShare(props.slots && props.slots.socialShare)}\n
{props.resources.shopText}
\n \n {shopSimilarLook && renderShopSimilarItem(shopSimilarLook)}\n {shopSimilarDescription && renderShopSimilarItem(shopSimilarDescription)}\n \n \n
{props.resources.descriptionText}
\n {description}\n
\n {ArrayExtensions.hasElements(props.slots.productSpecification) ? (\n {props.slots.productSpecification[0]}\n ) : null}\n
\n
\n );\n};\n\nexport default BuyboxView;\n","module.exports = React;","module.exports = ReactDOM;"],"names":["generateAddToOrderTemplateDialogResources","resources","addToOrderTemplateHeader","noOrderTemplatesMessage","noOrderTemplatesDescription","createAnOrderTemplateButtonText","createNewOrderTemplateButtonText","cancelOrderTemplateCreationButtonText","selectTemplatesText","addToTemplateButtonText","lineItemsText","generateOrderTemplateNameDialogResources","orderTemplateHeaderLabel","createOrderTemplateHeader","orderTemplateTitleLabel","orderTemplateTitle","orderTemplateNameAriaLabel","orderTemplateDescription","createOrderTemplateDescription","defaultOrderTemplateName","orderTemplateButtonLabel","createOrderTemplateButtonText","orderTemplateCancelButtonLabel","cancelNewOrderTemplateCreationButtonText","generateItemAddedToOrderTemplateDialogResources","viewOrderTemplateButtonText","continueShoppingButtonText","itemAddedToOrderTemplateHeaderItemOneText","itemAddedToOrderTemplateHeaderItemFormatText","itemAddedToOrderTemplateHeaderMessageText","freePriceText","priceFree","originalPriceText","currentPriceText","generateDuplicateItemsWhenAddingToOrderTemplateDialogResources","duplicatedProductsHeader","duplicatedProductsDescription","updateQuantityButtonText","cancelDuplicateItemsButtonText","onAddToOrderTemplateFailed","callbacks","product","result","updateErrorState","errorHost","configureErrors","status","getConfigureErrors","missingDimensions","IsGiftCard","BuyBoxConstants","onChangeHandler","newValue","updateQuantity","renderAddToOrderTemplate","props","state","data","addToOrderTemplate","orderTemplateButton","renderAddToOrderTemplateButton","id","typeName","context","orderTemplates","customerInformation","quantity","React","AddToOrderTemplateComponent","className","addToOrderTemplateButtonText","addToOrderTemplateButtonTooltip","addToOrderTemplateDialogResources","createOrderTemplateDialogResources","itemAddedToOrderTemplateDialogResources","duplicateItemsWhenAddingToOrderTemplateDialogResources","onError","shouldShowButtonFailedTooltip","isCustomPriceSelected","showButtonTooltip","showButtonText","Node","Object","assign","ContainerProps","errorBlock","onAddToWishlistFailed","renderAddToWishlist","addToWishlist","config","enableWishlist","wishlistButton","renderAddtoWishlistButton","wishlists","AddToWishlistComponent","addToWishlistButtonText","removeFromWishlistButtonText","addToWishlistMessage","removedFromWishlistMessage","addItemToWishlistError","removeItemFromWishlistError","nameOfWishlist","ariaRole","getSelectedProduct","selectedProduct","renderShopSimilarItem","shopSimilarItem","errors","input","renderConfigureDropdown","dropdown","LabelContainerProps","heading","select","_props$data$product$r","_props$data$storeSele","_props$data$product$r3","_props$data$productSp","_props$data$productSp2","_props$data$productSp3","_props$data$productSp4","_props$data$product$r6","_props$data$product$r7","_props$data$product$r8","ModuleProps","MediaGalleryContainerProps","ProductInfoContainerProps","addToCart","productComparisonButton","configure","description","findInStore","price","title","inventoryLabel","shopSimilarLook","keyInPrice","shopSimilarDescription","max","unitOfMeasure","quantityLimitsMessages","telemetryContent","app","appConfig","catalogs","skuText","ItemId","preferredStoreInfo","storeSelectorStateManager","preferredStore","preferredStoreId","StoreId","preferredStoreName","StoreName","availability","setAvailability","isStoreChange","setIsStoreChange","getInventory","async","_props$data$product$r2","GetFullAvailableInventoryNearbyInput","RecordId","zero","getFullAvailableInventoryNearby","actionContext","catch","error","telemetry","message","then","response","ArrayExtensions","hasElements","_preferredStoreAvaila","isPreferredStore","value","_value$OrgUnitAvailab","OrgUnitAvailability","OrgUnitLocation","OrgUnitNumber","filteredFullOrgUnitAvailability","filter","preferredStoreAvailability","undefined","stockStatusLabel","availabilityWithHours","ProductInventoryInformation","productInventoryInformation","_availabilityWithHour","InventoryLocationId","InventLocationId","StockLevelLabel","getStockInventoryLabel","resourceLabel","itemAvailabilities","ItemAvailabilities","enableStockCheck","AvailableQuantity","inStockText","outOfStockText","stockText","preferredStoreAvailabilityText","format","availabilityAtPreferredStoreText","displayStockAvailability","reaction","_props$data$storeSele2","selectedStoreLocationId","productSize","productSpecificationData","find","Name","productSizeAttributeName","brandName","brandNameAttributeName","productUnit","productUnitAttributeName","productIngredient","productIngredientAttributeName","Module","mediaGallery","TextValue","onClick","scrollToReviews","_document$getElementB","offsetTop","document","getElementById","window","scrollTo","top","behavior","BazaarVoiceStars","productId","withCount","sizeText","FloatValue","priceText","dropdowns","map","renderConfigure","renderKeyInPrice","renderQuantity","quantityComponent","extentionResources","IncrementalQuantity","currentCount","onChange","inputQuantityAriaLabel","decrementButtonAriaLabel","incrementButtonAriaLabel","minQuantityText","maxQuantityText","bulkPurchaseLink","stockAvailableText","renderAvailabilityAtPreferredStore","_props$data$product$r4","_props$data$product$r5","Dimensions","MasterProductId","tag","button","renderAddToCart","storeSelector","modal","productPickupOptionList","renderFindInStore","socialShare","length","_renderSocialShare","slots","descriptionText","Text","text","node","children","descriptionNode","productSpecification","BazaarVoiceReviewOverview","productName","isMultipleCatalogsFeatureEnabled","isChannelMultipleCatalogsFeatureEnabled","imageSettings","isMultipleCatalogFeatureEnabledInHq","catalogId","currentCatalogId","binding","modules","dataActions","registerSanitizedActionPath","sanitizedActionPath","dataAction","default","Error","prototype","RegistrationId","c","require","$type","da","name","path","runOn","iNM","ns","n","p","pdp","md","__bindings__","_objectSpread","viewDictionary","cn","BaseStoreSelectorStateManager","constructor","listMapViewState","displayList","displayMap","preferredStoreLocalStorageKey","this","isMapModuleLoaded","_readFromToCookie","storeInfo","JSON","parse","_unused","_context","storeId","storeName","writeToCookie","arguments","Latitude","Longitude","_writeToCookie","stringify","latitude","longitude","lastInlineShownStoreInfo","_removeCookie","key","MsDyn365","isBrowser","localStorage","removeItem","setItem","cookieValue","getItem","__decorate","computed","observable","action","MapStoreSelectorStateManager","SERVICE_ENDPOINT","MAP_API_ENDPOINT","searchTerm","requestContext","channel","BingMapsApiKey","BingMapsEnabled","searchContent","jsonp","crypto","getRandomValues","Uint32Array","ChannelCountryRegionISOCode","trim","query","encodeURI","geolocationApiUrl","requestUrl","Promise","resolve","script","createElement","setAttribute","remove","resourceSets","point","coordinates","body","appendChild","_document","StringExtensions","isNullOrEmpty","currentWindowAPI","mapAPIReady","isMapApiLoaded","url","lang","market","reject","_document2","_document3","type","defer","src","addEventListener","createStoreSelectorStateInput","GenericInput","getGenericActionDataAction","createObservableDataAction","getGenericAction","inputData","_renderTextBlock","textBlocks","_renderCartAndActions","_renderConfigure","_renderConfigureDropdown","_renderFindInStore","_renderQuantity","min","applyDefaultOrderSettings","_renderKeyInPrice","_renderShopSimilarItem","rating","shopText","module","exports","ReactDOM"],"sourceRoot":""}