@riosst100/pwa-marketplace 1.4.6 → 1.4.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/i18n/en_US.json +509 -509
- package/i18n/id_ID.json +29 -29
- package/package.json +1 -1
- package/src/componentOverrideMapping.js +3 -0
- package/src/components/BrandLandingPage/brandInfo.js +93 -0
- package/src/components/BrandLandingPage/brandLanding.js +255 -0
- package/src/components/BrandLandingPage/index.js +94 -0
- package/src/components/BrandLandingPage/menu.js +20 -0
- package/src/components/BrandListPage/banner_brands.png +0 -0
- package/src/components/BrandListPage/brandList.js +88 -0
- package/src/components/BrandListPage/index.js +57 -0
- package/src/components/BrandSlider/brandSlider.js +2 -2
- package/src/components/BrandSlider/item.js +24 -6
- package/src/components/CollectibleGameSets/collectibleGameSets.js +2 -1
- package/src/components/FilterTop/CustomFilters/customFilters.js +9 -7
- package/src/components/FilterTop/filterTop.js +2 -128
- package/src/components/Modal/index.js +10 -0
- package/src/components/Modal/modal.js +48 -0
- package/src/components/ProductLineSlider/index.js +1 -0
- package/src/components/ProductLineSlider/item.js +38 -0
- package/src/components/ProductLineSlider/logo_nendoroid.png +0 -0
- package/src/components/ProductLineSlider/nendroid-image.png +0 -0
- package/src/components/ProductLineSlider/productLineSlider.js +91 -0
- package/src/components/SocialMediaShare/index.js +51 -0
- package/src/components/SocialMediaShare/share.js +94 -0
- package/src/intercept.js +41 -27
- package/src/overwrites/venia-ui/lib/components/FilterModal/CurrentFilters/currentFilter.js +1 -1
- package/src/overwrites/venia-ui/lib/components/FilterModal/CurrentFilters/currentFilter.module.css +5 -4
- package/src/overwrites/venia-ui/lib/components/FilterModal/CurrentFilters/currentFilters.module.css +3 -1
- package/src/overwrites/venia-ui/lib/components/Footer/footer.js +147 -0
- package/src/overwrites/venia-ui/lib/components/Footer/footer.module.css +70 -0
- package/src/overwrites/venia-ui/lib/components/Footer/index.js +1 -0
- package/src/overwrites/venia-ui/lib/components/Footer/sampleData.js +48 -0
- package/src/overwrites/venia-ui/lib/components/Gallery/gallery.module.css +1 -1
- package/src/overwrites/venia-ui/lib/components/Main/index.js +1 -0
- package/src/overwrites/venia-ui/lib/components/Main/main.js +39 -0
- package/src/overwrites/venia-ui/lib/components/Main/main.module.css +41 -0
- package/src/overwrites/venia-ui/lib/components/MegaMenu/submenuColumn.js +14 -4
- package/src/overwrites/venia-ui/lib/components/MegaMenu/submenuColumn.module.css +2 -2
- package/src/overwrites/venia-ui/lib/components/Newsletter/index.js +1 -0
- package/src/overwrites/venia-ui/lib/components/Newsletter/newsletter.js +156 -0
- package/src/overwrites/venia-ui/lib/components/Newsletter/newsletter.module.css +90 -0
- package/src/overwrites/venia-ui/lib/components/Newsletter/newsletter.shimmer.js +46 -0
- package/src/overwrites/venia-ui/lib/components/Newsletter/newsletter.shimmer.module.css +21 -0
- package/src/overwrites/venia-ui/lib/components/ProductFullDetail/productFullDetail.js +23 -12
- package/src/overwrites/venia-ui/lib/components/TextInput/textInput.js +9 -1
- package/src/theme/vars.js +2 -0
package/src/intercept.js
CHANGED
|
@@ -23,38 +23,38 @@ module.exports = targets => {
|
|
|
23
23
|
|
|
24
24
|
// Tap into webpackCompiler
|
|
25
25
|
targets.of('@magento/pwa-buildpack').webpackCompiler.tap(compiler => {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
26
|
+
// Check if the LocalizationPlugin is present
|
|
27
|
+
if (compiler.options.plugins) {
|
|
28
|
+
const localizationPlugin = compiler.options.plugins.find(
|
|
29
|
+
plugin => plugin instanceof LocalizationPlugin
|
|
30
|
+
);
|
|
31
31
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
32
|
+
// Check if LocalizationPlugin is found
|
|
33
|
+
if (localizationPlugin) {
|
|
34
|
+
// Store the original mergeLocales function
|
|
35
|
+
const originalMergeLocales = localizationPlugin.mergeLocales;
|
|
36
36
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
}
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
// Return the modified mergedLocales
|
|
52
|
-
return originalMergeLocales.call(localizationPlugin, current, update);
|
|
37
|
+
// Define your custom hook
|
|
38
|
+
function myCustomMergeLocalesHook(current, update) {
|
|
39
|
+
// Modify the mergedLocales data here
|
|
40
|
+
Object.keys(update).forEach(key => {
|
|
41
|
+
if (typeof current[key] === 'undefined') {
|
|
42
|
+
current[key] = [];
|
|
43
|
+
}
|
|
44
|
+
if (Array.isArray(current[key]) && Array.isArray(update[key])) {
|
|
45
|
+
if (update[key].toString().includes("venia-ui")) {
|
|
46
|
+
delete update[key];
|
|
47
|
+
}
|
|
53
48
|
}
|
|
49
|
+
});
|
|
54
50
|
|
|
55
|
-
|
|
56
|
-
|
|
51
|
+
// Return the modified mergedLocales
|
|
52
|
+
return originalMergeLocales.call(localizationPlugin, current, update);
|
|
57
53
|
}
|
|
54
|
+
|
|
55
|
+
// Override mergeLocales with your custom hook
|
|
56
|
+
localizationPlugin.mergeLocales = myCustomMergeLocalesHook;
|
|
57
|
+
}
|
|
58
58
|
}
|
|
59
59
|
});
|
|
60
60
|
|
|
@@ -103,6 +103,20 @@ module.exports = targets => {
|
|
|
103
103
|
path: require.resolve("./components/CollectibleGameSetsPage/index.js"),
|
|
104
104
|
authed: false,
|
|
105
105
|
},
|
|
106
|
+
{
|
|
107
|
+
exact: true,
|
|
108
|
+
name: "BrandListPage",
|
|
109
|
+
pattern: "/brands",
|
|
110
|
+
path: require.resolve("./components/BrandListPage/index.js"),
|
|
111
|
+
authed: false,
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
exact: true,
|
|
115
|
+
name: "BrandLandingPage",
|
|
116
|
+
pattern: "/brand",
|
|
117
|
+
path: require.resolve("./components/BrandLandingPage/index.js"),
|
|
118
|
+
authed: false,
|
|
119
|
+
},
|
|
106
120
|
];
|
|
107
121
|
|
|
108
122
|
// Apply DefinePlugin using the results of the asynchronous operation
|
package/src/overwrites/venia-ui/lib/components/FilterModal/CurrentFilters/currentFilter.module.css
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
.root {
|
|
2
2
|
min-height: 24px;
|
|
3
|
-
composes:
|
|
4
|
-
|
|
3
|
+
composes: border from global;
|
|
4
|
+
composes: border-gray-100 from global;
|
|
5
|
+
composes: font-semibold from global;
|
|
5
6
|
composes: gap-2xs from global;
|
|
6
7
|
composes: grid-flow-col from global;
|
|
7
8
|
composes: inline-grid from global;
|
|
8
9
|
composes: items-center from global;
|
|
9
10
|
composes: justify-center from global;
|
|
10
11
|
composes: px-2 from global;
|
|
11
|
-
composes: py-
|
|
12
|
+
composes: py-1 from global;
|
|
12
13
|
composes: rounded-md from global;
|
|
13
14
|
/* composes: text-white from global; */
|
|
14
15
|
composes: text-base from global;
|
|
@@ -17,5 +18,5 @@
|
|
|
17
18
|
/* TODO @TW: cannot compose */
|
|
18
19
|
.root svg {
|
|
19
20
|
/* composes: stroke-white from global; */
|
|
20
|
-
stroke:
|
|
21
|
+
stroke: rgb(var(--venia-global-color-gray-600));
|
|
21
22
|
}
|
package/src/overwrites/venia-ui/lib/components/FilterModal/CurrentFilters/currentFilters.module.css
CHANGED
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
composes: px-[10px] from global;
|
|
3
3
|
composes: py-2 from global;
|
|
4
4
|
composes: overflow-auto from global;
|
|
5
|
-
composes:
|
|
5
|
+
composes: flex from global;
|
|
6
|
+
composes: flex-wrap from global;
|
|
7
|
+
composes: gap-2 from global;
|
|
6
8
|
}
|
|
7
9
|
|
|
8
10
|
/* TODO @TW: cannot compose */
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
import React, { Fragment } from 'react';
|
|
2
|
+
import { Facebook, Instagram, Twitter, Linkedin } from 'react-feather';
|
|
3
|
+
import { FormattedMessage, useIntl } from 'react-intl';
|
|
4
|
+
import { Link } from 'react-router-dom';
|
|
5
|
+
import { shape, string } from 'prop-types';
|
|
6
|
+
import { useFooter } from '@magento/peregrine/lib/talons/Footer/useFooter';
|
|
7
|
+
|
|
8
|
+
import Logo from '@magento/venia-ui/lib/components/Logo';
|
|
9
|
+
import Newsletter from '@magento/venia-ui/lib/components/Newsletter';
|
|
10
|
+
import { useStyle } from '@magento/venia-ui/lib/classify';
|
|
11
|
+
import defaultClasses from './footer.module.css';
|
|
12
|
+
import { DEFAULT_LINKS, LOREM_IPSUM } from './sampleData';
|
|
13
|
+
import resourceUrl from '@magento/peregrine/lib/util/makeUrl';
|
|
14
|
+
import cn from 'classnames';
|
|
15
|
+
import Divider from '@riosst100/pwa-marketplace/src/components/Divider';
|
|
16
|
+
|
|
17
|
+
const Footer = props => {
|
|
18
|
+
const { links } = props;
|
|
19
|
+
const classes = useStyle(defaultClasses, props.classes);
|
|
20
|
+
const talonProps = useFooter();
|
|
21
|
+
|
|
22
|
+
const { copyrightText } = talonProps;
|
|
23
|
+
const { formatMessage } = useIntl();
|
|
24
|
+
const title = formatMessage({ id: 'logo.title', defaultMessage: 'Venia' });
|
|
25
|
+
|
|
26
|
+
const linkGroups = Array.from(links, ([groupKey, linkProps]) => {
|
|
27
|
+
const linkElements = Array.from(linkProps, ([text, pathInfo]) => {
|
|
28
|
+
let path = pathInfo;
|
|
29
|
+
let Component = Fragment;
|
|
30
|
+
if (pathInfo && typeof pathInfo === 'object') {
|
|
31
|
+
path = pathInfo.path;
|
|
32
|
+
Component = pathInfo.Component;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
const itemKey = `text: ${text} path:${path}`;
|
|
36
|
+
const child = path ? (
|
|
37
|
+
<Link data-cy="Footer-link" className={classes.link} to={path}>
|
|
38
|
+
<FormattedMessage id={text} defaultMessage={text} />
|
|
39
|
+
</Link>
|
|
40
|
+
) : (
|
|
41
|
+
<span data-cy="Footer-label" className={classes.label}>
|
|
42
|
+
<FormattedMessage id={text} defaultMessage={text} />
|
|
43
|
+
</span>
|
|
44
|
+
);
|
|
45
|
+
|
|
46
|
+
return (
|
|
47
|
+
<Component key={itemKey}>
|
|
48
|
+
<li className={classes.linkItem}>{child}</li>
|
|
49
|
+
</Component>
|
|
50
|
+
);
|
|
51
|
+
});
|
|
52
|
+
|
|
53
|
+
return (
|
|
54
|
+
<ul key={groupKey} className={classes.linkGroup}>
|
|
55
|
+
{linkElements}
|
|
56
|
+
</ul>
|
|
57
|
+
);
|
|
58
|
+
});
|
|
59
|
+
|
|
60
|
+
return (
|
|
61
|
+
<footer
|
|
62
|
+
data-cy="Footer-root"
|
|
63
|
+
className={cn(
|
|
64
|
+
classes.root,
|
|
65
|
+
'!pt-[50px] !px-0'
|
|
66
|
+
)}
|
|
67
|
+
>
|
|
68
|
+
<div className={classes.links}>
|
|
69
|
+
{linkGroups}
|
|
70
|
+
<div>
|
|
71
|
+
<Newsletter />
|
|
72
|
+
</div>
|
|
73
|
+
<div className={classes.callout}>
|
|
74
|
+
<span
|
|
75
|
+
data-cy="Footer-calloutHeading"
|
|
76
|
+
className={classes.calloutHeading}
|
|
77
|
+
>
|
|
78
|
+
Follow Us
|
|
79
|
+
</span>
|
|
80
|
+
<ul className={classes.socialLinks}>
|
|
81
|
+
<li>
|
|
82
|
+
<Link to="" className="bg-darkblue-900 rounded-full flex justify-center items-center w-[34px] h-[34px]">
|
|
83
|
+
<Instagram size={15} color='#FFFFFF' />
|
|
84
|
+
</Link>
|
|
85
|
+
</li>
|
|
86
|
+
<li>
|
|
87
|
+
<Link to="" className="bg-darkblue-900 rounded-full flex justify-center items-center w-[34px] h-[34px]">
|
|
88
|
+
<Facebook size={15} color='#FFFFFF' />
|
|
89
|
+
</Link>
|
|
90
|
+
</li>
|
|
91
|
+
<li>
|
|
92
|
+
<Link to="" className="bg-darkblue-900 rounded-full flex justify-center items-center w-[34px] h-[34px]">
|
|
93
|
+
<Twitter size={15} color='#FFFFFF' />
|
|
94
|
+
</Link>
|
|
95
|
+
</li>
|
|
96
|
+
<li>
|
|
97
|
+
<Link to="" className="bg-darkblue-900 rounded-full flex justify-center items-center w-[34px] h-[34px]">
|
|
98
|
+
<svg width="14" height="16" viewBox="0 0 14 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
99
|
+
<path d="M12.9311 4.27218C12.8573 4.19836 12.7835 4.19836 12.6358 4.19836C12.4144 4.19836 12.2667 4.19836 12.0453 4.12454C10.7903 3.82925 9.90442 2.86957 9.8306 1.61459V1.31931C9.8306 1.09784 9.68295 0.950195 9.46148 0.950195H7.173C6.95154 0.950195 6.80389 1.09784 6.80389 1.31931V10.5471C6.80389 11.4329 6.06567 12.0973 5.25363 12.0973C4.73688 12.0973 4.29395 11.8758 3.99866 11.5067C3.4819 10.8423 3.62955 9.80883 4.29395 9.29208C4.58923 9.07061 4.88452 9.07061 5.4751 9.07061C5.54892 9.07061 5.69656 9.07061 5.77039 8.99679C5.84421 8.92297 5.91803 8.84915 5.91803 8.7015V6.26538C5.91803 6.11773 5.77039 5.89627 5.62274 5.89627C4.44159 5.74862 3.26044 6.04391 2.37457 6.78213C1.56253 7.52035 0.971956 8.55386 0.824312 9.80883C0.602846 11.2115 1.1196 12.6879 2.07929 13.6476C2.96515 14.6073 4.22012 15.0502 5.40128 15.0502C6.58243 15.0502 7.76358 14.6073 8.64944 13.7214C9.53531 12.8355 10.0521 11.6544 10.0521 10.3994V6.3392C10.9379 6.78213 11.8976 7.07742 12.8573 7.07742C13.0788 7.07742 13.2264 6.92978 13.2264 6.70831V4.49365C13.0788 4.41983 13.0049 4.34601 12.9311 4.27218Z" fill="white" />
|
|
100
|
+
</svg>
|
|
101
|
+
</Link>
|
|
102
|
+
</li>
|
|
103
|
+
<li>
|
|
104
|
+
<Link to="" className="bg-darkblue-900 rounded-full flex justify-center items-center w-[34px] h-[34px]">
|
|
105
|
+
<Linkedin size={15} color='#FFFFFF' />
|
|
106
|
+
</Link>
|
|
107
|
+
</li>
|
|
108
|
+
</ul>
|
|
109
|
+
</div>
|
|
110
|
+
</div>
|
|
111
|
+
<div className="flex flex-row justify-between py-2 border-t border-gray-100">
|
|
112
|
+
<p className="text-colorDefault">{copyrightText || null}</p>
|
|
113
|
+
<ul className="flex flex-row gap-x-2.5">
|
|
114
|
+
<li data-cy="Footer-terms" className={classes.terms}>
|
|
115
|
+
<Link to="/" className="text-colorDefault underline">
|
|
116
|
+
<FormattedMessage
|
|
117
|
+
id={'footer.termsText'}
|
|
118
|
+
defaultMessage={'Terms of Use'}
|
|
119
|
+
/>
|
|
120
|
+
</Link>
|
|
121
|
+
</li>
|
|
122
|
+
<Divider className="w-[1px] !h-[20px]" />
|
|
123
|
+
<li data-cy="Footer-privacy" className={classes.privacy}>
|
|
124
|
+
<Link to="/" className="text-colorDefault underline">
|
|
125
|
+
<FormattedMessage
|
|
126
|
+
id={'footer.privacyText'}
|
|
127
|
+
defaultMessage={'Privacy Policy'}
|
|
128
|
+
/>
|
|
129
|
+
</Link>
|
|
130
|
+
</li>
|
|
131
|
+
</ul>
|
|
132
|
+
</div>
|
|
133
|
+
</footer>
|
|
134
|
+
);
|
|
135
|
+
};
|
|
136
|
+
|
|
137
|
+
export default Footer;
|
|
138
|
+
|
|
139
|
+
Footer.defaultProps = {
|
|
140
|
+
links: DEFAULT_LINKS
|
|
141
|
+
};
|
|
142
|
+
|
|
143
|
+
Footer.propTypes = {
|
|
144
|
+
classes: shape({
|
|
145
|
+
root: string
|
|
146
|
+
})
|
|
147
|
+
};
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
.root {
|
|
2
|
+
composes: border-t from global;
|
|
3
|
+
composes: border-solid from global;
|
|
4
|
+
composes: border-gray-100 from global;
|
|
5
|
+
composes: gap-y-16 from global;
|
|
6
|
+
composes: grid from global;
|
|
7
|
+
composes: leading-normal from global;
|
|
8
|
+
composes: max-w-site from global;
|
|
9
|
+
composes: min-h-[15rem] from global;
|
|
10
|
+
composes: mx-auto from global;
|
|
11
|
+
composes: my-0 from global;
|
|
12
|
+
composes: pt-16 from global;
|
|
13
|
+
composes: text-sm from global;
|
|
14
|
+
composes: text-subtle from global;
|
|
15
|
+
composes: w-full from global;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.links {
|
|
19
|
+
composes: gap-x-md from global;
|
|
20
|
+
composes: gap-y-lg from global;
|
|
21
|
+
composes: grid from global;
|
|
22
|
+
composes: grid-cols-1 from global;
|
|
23
|
+
composes: md_grid-cols-1 from global;
|
|
24
|
+
composes: grid-flow-row-dense from global;
|
|
25
|
+
composes: lg_gap-x-sm from global;
|
|
26
|
+
composes: lg_gap-y-md from global;
|
|
27
|
+
composes: lg_grid-cols-4 from global;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.linkGroup {
|
|
31
|
+
/* composes: col-span-3 from global; */
|
|
32
|
+
composes: content-start from global;
|
|
33
|
+
composes: gap-xs from global;
|
|
34
|
+
composes: grid from global;
|
|
35
|
+
|
|
36
|
+
/* composes: xs_col-span-2 from global; */
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.linkItem {
|
|
40
|
+
composes: first_text-colorDefault from global;
|
|
41
|
+
composes: first_font-semibold from global;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.callout {
|
|
45
|
+
/* composes: col-span-3 from global; */
|
|
46
|
+
composes: leading-normal from global;
|
|
47
|
+
composes: max-w-[20rem] from global;
|
|
48
|
+
composes: text-sm from global;
|
|
49
|
+
composes: flex from global;
|
|
50
|
+
composes: flex-col from global;
|
|
51
|
+
composes: gap-y-[15px] from global;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.calloutHeading {
|
|
55
|
+
composes: font-semibold from global;
|
|
56
|
+
composes: text-colorDefault from global;
|
|
57
|
+
composes: text-sm from global;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.calloutBody {
|
|
61
|
+
composes: mx-0 from global;
|
|
62
|
+
composes: my-xs from global;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.socialLinks {
|
|
66
|
+
composes: gap-xs from global;
|
|
67
|
+
composes: grid from global;
|
|
68
|
+
composes: grid-flow-col from global;
|
|
69
|
+
composes: justify-start from global;
|
|
70
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './footer';
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { ContactLink } from '@magento/venia-ui/lib/components/ContactPage';
|
|
2
|
+
|
|
3
|
+
const accountLinks = new Map()
|
|
4
|
+
.set('Account', null)
|
|
5
|
+
.set('Sign In', '/')
|
|
6
|
+
.set('Register', '/')
|
|
7
|
+
.set('Tracking Order', '/')
|
|
8
|
+
|
|
9
|
+
const getToKnowUsLinks = new Map()
|
|
10
|
+
.set('About TCG Collective', null)
|
|
11
|
+
.set('Career', '/')
|
|
12
|
+
.set('Contact Us', '/')
|
|
13
|
+
.set('Help Center', '/')
|
|
14
|
+
.set('Intelectual Property Claims', '/');
|
|
15
|
+
|
|
16
|
+
const aboutLinks = new Map()
|
|
17
|
+
.set('About Us', '/about-us')
|
|
18
|
+
.set('Our Story', null)
|
|
19
|
+
.set('Email Signup', null)
|
|
20
|
+
.set('Give Back', null);
|
|
21
|
+
|
|
22
|
+
const sitesLinks = new Map()
|
|
23
|
+
.set('Sites', null)
|
|
24
|
+
.set('International', '/')
|
|
25
|
+
.set('Singapore', '/')
|
|
26
|
+
.set('Malaysia', '/')
|
|
27
|
+
.set('Indonesia', '/')
|
|
28
|
+
.set('Thailand', '/')
|
|
29
|
+
.set('Philippines', '/')
|
|
30
|
+
.set('Vietnam', '/')
|
|
31
|
+
|
|
32
|
+
const helpLinks = new Map()
|
|
33
|
+
.set('Help', null)
|
|
34
|
+
.set('Customer Service', '/customer-service')
|
|
35
|
+
.set('Contact Us', {
|
|
36
|
+
path: '/contact-us',
|
|
37
|
+
Component: ContactLink
|
|
38
|
+
})
|
|
39
|
+
.set('Order Status', null)
|
|
40
|
+
.set('Returns', null);
|
|
41
|
+
|
|
42
|
+
export const DEFAULT_LINKS = new Map()
|
|
43
|
+
.set('us', getToKnowUsLinks)
|
|
44
|
+
.set('account', accountLinks)
|
|
45
|
+
.set('sites', sitesLinks);
|
|
46
|
+
|
|
47
|
+
export const LOREM_IPSUM =
|
|
48
|
+
'Lorem ipsum dolor sit amet, consectetur adipsicing elit, sed do eiusmod tempor incididunt ut labore et dolore.';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './main';
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { bool, shape, string } from 'prop-types';
|
|
3
|
+
import { useScrollLock } from '@magento/peregrine';
|
|
4
|
+
|
|
5
|
+
import { useStyle } from '@magento/venia-ui/lib/classify';
|
|
6
|
+
import Footer from '@magento/venia-ui/lib/components/Footer';
|
|
7
|
+
import Header from '@magento/venia-ui/lib/components/Header';
|
|
8
|
+
import defaultClasses from './main.module.css';
|
|
9
|
+
import cn from 'classnames';
|
|
10
|
+
|
|
11
|
+
const Main = props => {
|
|
12
|
+
const { children, isMasked } = props;
|
|
13
|
+
const classes = useStyle(defaultClasses, props.classes);
|
|
14
|
+
|
|
15
|
+
const rootClass = isMasked ? classes.root_masked : classes.root;
|
|
16
|
+
const pageClass = isMasked ? classes.page_masked : classes.page;
|
|
17
|
+
|
|
18
|
+
useScrollLock(isMasked);
|
|
19
|
+
|
|
20
|
+
return (
|
|
21
|
+
<main className={rootClass}>
|
|
22
|
+
<Header />
|
|
23
|
+
<div className={cn(pageClass, 'main-content-container pb-16')}>{children}</div>
|
|
24
|
+
<Footer />
|
|
25
|
+
</main>
|
|
26
|
+
);
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export default Main;
|
|
30
|
+
|
|
31
|
+
Main.propTypes = {
|
|
32
|
+
classes: shape({
|
|
33
|
+
page: string,
|
|
34
|
+
page_masked: string,
|
|
35
|
+
root: string,
|
|
36
|
+
root_masked: string
|
|
37
|
+
}),
|
|
38
|
+
isMasked: bool
|
|
39
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
.root {
|
|
2
|
+
composes: bg-white from global;
|
|
3
|
+
composes: relative from global;
|
|
4
|
+
composes: text-colorDefault from global;
|
|
5
|
+
composes: z-foreground from global;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.root_masked {
|
|
9
|
+
composes: root;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.page {
|
|
13
|
+
composes: md_max-w-screen-md from global;
|
|
14
|
+
composes: lg_max-w-[1210px] from global;
|
|
15
|
+
composes: mx-auto from global;
|
|
16
|
+
composes: my-0 from global;
|
|
17
|
+
composes: px-[15px] from global;
|
|
18
|
+
min-height: 40rem;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.page_masked {
|
|
22
|
+
composes: page;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
@media (min-height: 640px) {
|
|
26
|
+
.page {
|
|
27
|
+
min-height: 48rem;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
@media (min-height: 768px) {
|
|
32
|
+
.page {
|
|
33
|
+
min-height: 60rem;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
@media (min-height: 960px) {
|
|
38
|
+
.page {
|
|
39
|
+
min-height: 72rem;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -76,17 +76,27 @@ const SubmenuColumn = props => {
|
|
|
76
76
|
<li key={index} className={classes.submenuChildItem}>
|
|
77
77
|
{customMenuItems.length ? (
|
|
78
78
|
<>
|
|
79
|
-
<
|
|
80
|
-
|
|
79
|
+
<Link
|
|
80
|
+
{...keyboardProps}
|
|
81
81
|
className={isActive ? classes.linkActive : classes.link}
|
|
82
82
|
data-cy="MegaMenu-SubmenuColumn-link"
|
|
83
|
+
to={categoryUrl}
|
|
83
84
|
onClick={() => {
|
|
84
|
-
|
|
85
|
+
handleCloseSubMenu();
|
|
86
|
+
onNavigate();
|
|
85
87
|
}}
|
|
86
88
|
>
|
|
87
89
|
{name}
|
|
90
|
+
</Link>
|
|
91
|
+
<span
|
|
92
|
+
className={isActive ? classes.linkActive : classes.link}
|
|
93
|
+
data-cy="MegaMenu-SubmenuColumn-link"
|
|
94
|
+
onClick={() => {
|
|
95
|
+
toggleCustomMenu();
|
|
96
|
+
}}
|
|
97
|
+
>
|
|
88
98
|
{arrow}
|
|
89
|
-
</
|
|
99
|
+
</span>
|
|
90
100
|
{showCustomMenu ? customSubMenus : ''}
|
|
91
101
|
</>
|
|
92
102
|
) : (
|
|
@@ -15,13 +15,13 @@
|
|
|
15
15
|
composes: hover_underline from global;
|
|
16
16
|
|
|
17
17
|
align-items: center;
|
|
18
|
-
composes: flex from global;
|
|
18
|
+
composes: inline-flex from global;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
21
|
.linkActive {
|
|
22
22
|
composes: underline from global;
|
|
23
23
|
align-items: center;
|
|
24
|
-
composes: flex from global;
|
|
24
|
+
composes: inline-flex from global;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
.submenuChild {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './newsletter';
|