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Commerce/./src/themes/dobbiesclub/views/footer-category.view.tsx?7ec9","webpack://Dobbies.Commerce/./lib/footer-category/module-registration.js?7500","webpack://Dobbies.Commerce/./src/modules/footer-category/footer-category.tsx?e0bd","webpack://Dobbies.Commerce/./src/modules/footer-category/footer-category.view.tsx?fdce","webpack://Dobbies.Commerce/external var \"React\"?0d3b","webpack://Dobbies.Commerce/external var \"ReactDOM\"?853b"],"sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * Licensed under the MIT License. See License.txt in the project root for license information.\r\n *--------------------------------------------------------------------------------------------*/\r\n\r\nimport { IFooterCategoryViewProps } from '@msdyn365-commerce-modules/footer/src/modules/footer-category/./footer-category';\r\nimport { addThrottledEvent, Module, Node } from '@msdyn365-commerce-modules/utilities';\r\nimport { ICoreContext } from '@msdyn365-commerce/core';\r\nimport React, { ReactNode, useEffect, useState } from 'react';\r\n\r\nimport classnames from 'classnames';\r\nimport { IFooterCategoryProps } from '../definition-extensions/footer-category.ext.props.autogenerated';\r\n\r\nexport const FooterCategoryView: React.FC> = props => {\r\n /* VSI Customization - START */\r\n /* isOpen shows if a collapse is open or not */\r\n const [isOpen, setIsOpen] = useState(false);\r\n const [isMobile, setIsMobile] = useState(false);\r\n /* VSI Customization - END */\r\n const {\r\n categories,\r\n FooterList,\r\n FooterListItem,\r\n config: { collapseItems }\r\n } = props;\r\n if (!categories || !categories.length) {\r\n props.context.telemetry.error('Footer content is empty, module wont render');\r\n return null;\r\n }\r\n\r\n /* VSI Customization - START */\r\n /* condition either to show or hide the header */\r\n if (props.context.request.query!.onlyBody && props.context.request.query!.onlyBody === 'true') {\r\n return null;\r\n }\r\n /* useEffect will update footer according to device type */\r\n useEffect(() => {\r\n setMobileView();\r\n window && addThrottledEvent(window, 'resize', setMobileView);\r\n });\r\n\r\n const setMobileView = () => {\r\n const _isMobile = isMobileView(props.context);\r\n setIsMobile(_isMobile);\r\n };\r\n /* Click on collapse will toggle it */\r\n const _handleCollapse = (event: MouseEvent) => {\r\n setIsOpen(!isOpen);\r\n };\r\n /* collapse will only be shown on mobile */\r\n let _collapse = isMobile ? true : false;\r\n /* On mobile, category with Collapse value false will not be shown as collapse */\r\n if (_collapse) {\r\n _collapse = collapseItems === false ? false : true;\r\n }\r\n /* VSI Customization - END */\r\n return (\r\n \r\n {/* VSI Customization - START */}\r\n {_collapse ? (\r\n \r\n \r\n {categories[0]}\r\n \r\n\r\n
\r\n {categories.map((category: ReactNode, index: number) => {\r\n if (index > 0) {\r\n return (\r\n \r\n {category}\r\n \r\n );\r\n }\r\n return null;\r\n })}\r\n
\r\n
\r\n ) : (\r\n \r\n {categories.map((category: ReactNode, index: number) => {\r\n return (\r\n \r\n {category}\r\n \r\n );\r\n })}\r\n \r\n )}\r\n {/* VSI Customization - END */}\r\n
\r\n );\r\n};\r\n\r\n/* VSI Customization - START */\r\nconst isMobileView = (context: ICoreContext): boolean => {\r\n if (typeof window !== undefined && window.innerWidth) {\r\n const gridSettings = context.request.gridSettings;\r\n if (gridSettings) {\r\n if (gridSettings.xs && window.innerWidth < gridSettings.xs.w) {\r\n return true;\r\n } else if (gridSettings.sm && window.innerWidth < gridSettings.sm.w) {\r\n return true;\r\n } else if (gridSettings.md && window.innerWidth <= gridSettings.md.w) {\r\n return false;\r\n } else if (gridSettings.lg && window.innerWidth <= gridSettings.lg.w) {\r\n return false;\r\n } else {\r\n return false;\r\n }\r\n }\r\n }\r\n\r\n return false;\r\n};\r\n/* VSI Customization - END */\r\n\r\nexport default FooterCategoryView;\r\n","/*---------------------------------------------------------------------------------------------\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * Licensed under the MIT License. See License.txt in the project root for license information.\r\n *--------------------------------------------------------------------------------------------*/\r\n\r\nimport { IFooterCategoryViewProps } from '@msdyn365-commerce-modules/footer/src/modules/footer-category/./footer-category';\r\nimport { addThrottledEvent, Collapse, Module, Node } from '@msdyn365-commerce-modules/utilities';\r\nimport { ICoreContext } from '@msdyn365-commerce/core';\r\nimport React, { ReactNode, useEffect, useState } from 'react';\r\n\r\nimport classnames from 'classnames';\r\nimport { IFooterCategoryProps } from '../definition-extensions/footer-category.ext.props.autogenerated';\r\n\r\nexport const FooterCategoryView: React.FC> = props => {\r\n /* VSI Customization - START */\r\n /* isOpen shows if a collapse is open or not */\r\n const [isOpen, setIsOpen] = useState(false);\r\n const [isMobile, setIsMobile] = useState(false);\r\n /* VSI Customization - END */\r\n const {\r\n categories,\r\n FooterList,\r\n FooterListItem,\r\n config: { collapseItems }\r\n } = props;\r\n if (!categories || !categories.length) {\r\n props.context.telemetry.error('Footer content is empty, module wont render');\r\n return null;\r\n }\r\n /* VSI Customization - START */\r\n /* useEffect will update footer according to device type */\r\n useEffect(() => {\r\n setMobileView();\r\n window && addThrottledEvent(window, 'resize', setMobileView);\r\n });\r\n\r\n const setMobileView = () => {\r\n const _isMobile = isMobileView(props.context);\r\n setIsMobile(_isMobile);\r\n };\r\n /* Click on collapse will toggle it */\r\n const _handleCollapse = (event: MouseEvent) => {\r\n setIsOpen(!isOpen);\r\n };\r\n /* collapse will only be shown on mobile */\r\n let _collapse = isMobile ? true : false;\r\n /* On mobile, category with Collapse value false will not be shown as collapse */\r\n if (_collapse) {\r\n _collapse = collapseItems === false ? false : true;\r\n }\r\n /* VSI Customization - END */\r\n return (\r\n \r\n {/* VSI Customization - START */}\r\n {_collapse ? (\r\n \r\n \r\n {categories[0]}\r\n \r\n \r\n {categories.map((category: ReactNode, index: number) => {\r\n if (index > 0) {\r\n return (\r\n \r\n {category}\r\n \r\n );\r\n }\r\n return null;\r\n })}\r\n \r\n \r\n ) : (\r\n \r\n {categories.map((category: ReactNode, index: number) => {\r\n return (\r\n \r\n {category}\r\n \r\n );\r\n })}\r\n \r\n )}\r\n {/* VSI Customization - END */}\r\n \r\n );\r\n};\r\n\r\n/* VSI Customization - START */\r\nconst isMobileView = (context: ICoreContext): boolean => {\r\n if (typeof window !== undefined && window.innerWidth) {\r\n const gridSettings = context.request.gridSettings;\r\n if (gridSettings) {\r\n if (gridSettings.xs && window.innerWidth < gridSettings.xs.w) {\r\n return true;\r\n } else if (gridSettings.sm && window.innerWidth < gridSettings.sm.w) {\r\n return true;\r\n } else if (gridSettings.md && window.innerWidth <= gridSettings.md.w) {\r\n return false;\r\n } else if (gridSettings.lg && window.innerWidth <= gridSettings.lg.w) {\r\n return false;\r\n } else {\r\n return false;\r\n }\r\n }\r\n }\r\n\r\n return false;\r\n};\r\n/* VSI Customization - END */\r\n\r\nexport default FooterCategoryView;\r\n","const binding = { modules: {}, dataActions: {} };\n\n (binding.modules['footer-category'] = {\n c: () => require('@msdyn365-commerce-modules/footer/dist/lib/modules/footer-category/footer-category'),\n $type: 'containerModule',\n da: [],\n \n iNM: true,\n ns: '@msdyn365-commerce-modules',\n n: 'footer-category',\n p: 'footer',\n \n pdp: '',\n \n \n md: 'node_modules/@msdyn365-commerce-modules/footer/dist/lib/modules/footer-category'\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|dobbies|views|footer-category'] = {\n c: () => require('partner/themes/dobbies/views/footer-category.view.tsx'),\n cn: '__local__-__local__-footer-category'\n };\nviewDictionary['__local__|__local__|themes|dobbiesclub|views|footer-category'] = {\n c: () => require('partner/themes/dobbiesclub/views/footer-category.view.tsx'),\n cn: '__local__-__local__-footer-category'\n };\nviewDictionary['@msdyn365-commerce-modules|footer|modules|footer-category|footer-category'] = {\n c: () => require('@msdyn365-commerce-modules/footer/dist/lib/modules/footer-category/footer-category.view.js'),\n cn: '@msdyn365-commerce-modules-footer-footer-category'\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 { IModuleProps, INodeProps } from '@msdyn365-commerce-modules/utilities';\nimport classnames from 'classnames';\nimport * as React from 'react';\n\nimport { IFooterCategoryConfig, IFooterCategoryProps } from './footer-category.props.autogenerated';\n\nexport interface IFooterCategoryViewProps extends IFooterCategoryProps {\n categories: React.ReactNode[];\n FooterList: IModuleProps;\n FooterListItem: INodeProps;\n}\n\n/**\n *\n * FooterCategory component.\n * @extends {React.PureComponent>}\n */\nclass FooterCategory extends React.PureComponent> {\n public render(): JSX.Element | null {\n if (!this.props.slots || !this.props.slots.content || this.props.slots.content.length === 0) {\n this.props.context.telemetry.error('footer slots content is empty, module wont render');\n return null;\n }\n const viewprops = {\n ...this.props,\n categories: this.props.slots.content,\n FooterList: {\n moduleProps: this.props,\n className: classnames('ms-footer__list', this.props.config.className),\n tag: 'ul'\n },\n FooterListItem: {\n className: classnames('ms-footer__list-item', this.props.config.className),\n tag: 'li'\n }\n };\n\n return this.props.renderView(viewprops) as React.ReactElement;\n }\n}\n\nexport default FooterCategory;\n","/*!\n * Copyright (c) Microsoft Corporation.\n * All rights reserved. See LICENSE in the project root for license information.\n */\n\nimport { Module, Node } from '@msdyn365-commerce-modules/utilities';\nimport React, { ReactNode } from 'react';\n\nimport { IFooterCategoryViewProps } from './footer-category';\n\nexport const FooterCategoryView: React.FC = props => {\n const { categories, FooterList, FooterListItem } = props;\n if (!categories || categories.length === 0) {\n props.context.telemetry.error('Footer content is empty, module wont render');\n return null;\n }\n return (\n \n {categories.map((category: ReactNode, index: number) => {\n return (\n \n {category}\n \n );\n })}\n \n );\n};\n\nexport default FooterCategoryView;\n","module.exports = React;","module.exports = ReactDOM;"],"names":["FooterCategoryView","props","isOpen","setIsOpen","useState","isMobile","setIsMobile","categories","FooterList","FooterListItem","config","collapseItems","length","context","telemetry","error","request","query","onlyBody","useEffect","setMobileView","window","addThrottledEvent","_isMobile","isMobileView","_collapse","React","Module","Object","assign","Node","className","classnames","onClick","event","map","category","index","key","undefined","innerWidth","gridSettings","xs","w","sm","md","lg","Collapse","timeout","binding","modules","dataActions","c","require","$type","da","iNM","ns","n","p","pdp","__bindings__","_objectSpread","viewDictionary","cn","FooterCategory","render","this","slots","content","viewprops","moduleProps","tag","renderView","module","exports","ReactDOM"],"sourceRoot":""}