gatsby-matrix-theme 37.0.48 → 38.0.0
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/CHANGELOG.md +35 -0
- package/package.json +2 -2
- package/src/components/molecules/toplist/row/variant-one.js +3 -1
- package/src/gatsby-core-theme/components/molecules/search/index.js +16 -1
- package/src/gatsby-core-theme/components/organisms/toplist/index.js +6 -0
- package/src/gatsby-core-theme/hooks/tabs/index.js +12 -0
- package/src/gatsby-core-theme/hooks/tabs/tab/tab-list.js +17 -2
- package/src/gatsby-core-theme/hooks/tabs/tab/tab.js +8 -1
- package/storybook/public/{408.b5217ccb.iframe.bundle.js → 408.a33c5f6f.iframe.bundle.js} +2 -2
- package/storybook/public/555.3f84c9c5.iframe.bundle.js +1 -0
- package/storybook/public/60.972148b9.iframe.bundle.js +1 -0
- package/storybook/public/{837.ea39f52e.iframe.bundle.js → 837.f937bc4a.iframe.bundle.js} +4 -4
- package/storybook/public/{837.ea39f52e.iframe.bundle.js.map → 837.f937bc4a.iframe.bundle.js.map} +1 -1
- package/storybook/public/iframe.html +1 -1
- package/storybook/public/main.661d8cff.iframe.bundle.js +2 -0
- package/storybook/public/{runtime~main.e5bd1e19.iframe.bundle.js → runtime~main.8bbe821d.iframe.bundle.js} +1 -1
- package/storybook/public/555.5bc1a378.iframe.bundle.js +0 -1
- package/storybook/public/60.ba168f61.iframe.bundle.js +0 -1
- package/storybook/public/main.f721a9c6.iframe.bundle.js +0 -2
- /package/storybook/public/{408.b5217ccb.iframe.bundle.js.LICENSE.txt → 408.a33c5f6f.iframe.bundle.js.LICENSE.txt} +0 -0
- /package/storybook/public/{837.ea39f52e.iframe.bundle.js.LICENSE.txt → 837.f937bc4a.iframe.bundle.js.LICENSE.txt} +0 -0
- /package/storybook/public/{main.f721a9c6.iframe.bundle.js.LICENSE.txt → main.661d8cff.iframe.bundle.js.LICENSE.txt} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,38 @@
|
|
|
1
|
+
# [38.0.0](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v37.0.49...v38.0.0) (2024-01-08)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* updated theme ([5f93eab](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/5f93eab6141ca874783e3b42e2cd7fe83b5ec0a1))
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Code Refactoring
|
|
10
|
+
|
|
11
|
+
* changes to search tabs to show number of results ([00188c3](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/00188c3bab21f488367318b80ed0d635295a7a65))
|
|
12
|
+
* hide search results on tab by default ([dbfb50e](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/dbfb50e76b4fb65e10bc3ce13133a88767f389fa))
|
|
13
|
+
* remove author component from search pages ([04c89dc](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/04c89dc0d2a5c561e427e81c0bdfa00b716c1784))
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
### Config
|
|
17
|
+
|
|
18
|
+
* update to latest ([1d37dda](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/1d37ddacebe8cb09a3d6f7df525a304861c034ce))
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
* Merge branch 'search-tab-changes' into 'master' ([b860687](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/b860687e8410b5c9aeb7dd8799478bd3a98d312d))
|
|
22
|
+
* Merge branch 'master' into search-tab-changes ([3601550](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/3601550fecdc18cfcbf4ce927e8956d8af1c2761))
|
|
23
|
+
* Merge branch 'master' into search-tab-changes ([6129e5d](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/6129e5d7da7ea36036dc9c96816bd05acb1a3642))
|
|
24
|
+
* Merge branch 'master' into search-tab-changes ([a972605](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/a972605085b309cbbf87231fe09dfdcc9ccde0e0))
|
|
25
|
+
|
|
26
|
+
## [37.0.49](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v37.0.48...v37.0.49) (2024-01-05)
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
### Bug Fixes
|
|
30
|
+
|
|
31
|
+
* added prop to hide selling points ([61c9ccc](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/61c9cccec614614cf92921cf231d3d7ad14e72b0))
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
* Merge branch 'tm-3725-ocl-changes' into 'master' ([a569626](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/a569626fd4228738ce28b334c3f9e13ae624e8e0))
|
|
35
|
+
|
|
1
36
|
## [37.0.48](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v37.0.47...v37.0.48) (2024-01-05)
|
|
2
37
|
|
|
3
38
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gatsby-matrix-theme",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "38.0.0",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"description": "Matrix Theme NPM Package",
|
|
6
6
|
"author": "",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@react-icons/all-files": "^4.1.0",
|
|
27
27
|
"gatsby": "^5.11.0",
|
|
28
|
-
"gatsby-core-theme": "30.0.
|
|
28
|
+
"gatsby-core-theme": "30.0.46",
|
|
29
29
|
"gatsby-plugin-sharp": "^5.11.0",
|
|
30
30
|
"gatsby-plugin-sitemap": "^3.3.0",
|
|
31
31
|
"gatsby-transformer-sharp": "^5.11.0",
|
|
@@ -18,6 +18,7 @@ export default function Row({
|
|
|
18
18
|
className,
|
|
19
19
|
itemRefs,
|
|
20
20
|
authorTemplateTwo = false,
|
|
21
|
+
showSellingPoints = true,
|
|
21
22
|
showAuthor,
|
|
22
23
|
useOneStarRating,
|
|
23
24
|
template,
|
|
@@ -53,7 +54,7 @@ export default function Row({
|
|
|
53
54
|
|
|
54
55
|
<Bonus item={item} tracker={oneliner} />
|
|
55
56
|
|
|
56
|
-
<SellingPoints sellingPoints={sellingPoints} limit={3} />
|
|
57
|
+
{showSellingPoints && <SellingPoints sellingPoints={sellingPoints} limit={3} />}
|
|
57
58
|
|
|
58
59
|
<OperatorCta
|
|
59
60
|
operator={item}
|
|
@@ -94,6 +95,7 @@ Row.propTypes = {
|
|
|
94
95
|
index: PropTypes.number,
|
|
95
96
|
className: PropTypes.string,
|
|
96
97
|
tracker: PropTypes.string,
|
|
98
|
+
showSellingPoints: PropTypes.bool,
|
|
97
99
|
oneliner: PropTypes.string,
|
|
98
100
|
layout: PropTypes.oneOf(['list', 'grid']),
|
|
99
101
|
item: PropTypes.shape({
|
|
@@ -35,6 +35,9 @@ const Search = ({
|
|
|
35
35
|
noResults = 'We can’t find anything that matches your query. Please try again with other keywords.',
|
|
36
36
|
page,
|
|
37
37
|
pageContext,
|
|
38
|
+
showTabIcon = false,
|
|
39
|
+
icon = null,
|
|
40
|
+
showNumberOfResults = false,
|
|
38
41
|
}) => {
|
|
39
42
|
const { setShowSearch } = useContext(NavigationContext);
|
|
40
43
|
const pageSearchOptionsCopy = pageSearchOptions;
|
|
@@ -355,6 +358,10 @@ const Search = ({
|
|
|
355
358
|
activeTabClass="searchActive"
|
|
356
359
|
headerClass="searchHeader"
|
|
357
360
|
gtmClass="search-tabs-menu-gtm"
|
|
361
|
+
showIcon={showTabIcon}
|
|
362
|
+
icon={icon}
|
|
363
|
+
showNumberOfResults={showNumberOfResults}
|
|
364
|
+
totalResults={searchResultsRef?.current?.length}
|
|
358
365
|
>
|
|
359
366
|
{items}
|
|
360
367
|
</Tabs>
|
|
@@ -399,7 +406,12 @@ const Search = ({
|
|
|
399
406
|
const Archive = loadable(() => import('~organisms/archive'));
|
|
400
407
|
|
|
401
408
|
return (
|
|
402
|
-
<div
|
|
409
|
+
<div
|
|
410
|
+
results={items?.items?.length}
|
|
411
|
+
label={titleObj.title}
|
|
412
|
+
tabId={type + index}
|
|
413
|
+
key={keygen()}
|
|
414
|
+
>
|
|
403
415
|
{pageSearchOptionsCopy.useArchive === undefined ||
|
|
404
416
|
!pageSearchOptionsCopy.useArchive ? (
|
|
405
417
|
<div className={styles?.searchGrid || ''}>{items}</div>
|
|
@@ -488,6 +500,9 @@ Search.propTypes = {
|
|
|
488
500
|
market: PropTypes.string,
|
|
489
501
|
}),
|
|
490
502
|
}),
|
|
503
|
+
showTabIcon: PropTypes.bool,
|
|
504
|
+
icon: PropTypes.func,
|
|
505
|
+
showNumberOfResults: PropTypes.bool,
|
|
491
506
|
};
|
|
492
507
|
|
|
493
508
|
export default Search;
|
|
@@ -15,6 +15,8 @@ const TopList = ({
|
|
|
15
15
|
isHomepageFirstModule = false,
|
|
16
16
|
showAffiliateDisclaimer = true,
|
|
17
17
|
verifyIcon = '../../../../images/verifiedAuthor.svg',
|
|
18
|
+
showIcon = false,
|
|
19
|
+
icon = null,
|
|
18
20
|
}) => {
|
|
19
21
|
const showTabs = module.items.length > 1;
|
|
20
22
|
const moduleStyle = module?.style;
|
|
@@ -52,6 +54,8 @@ const TopList = ({
|
|
|
52
54
|
moduleStyle={moduleStyle}
|
|
53
55
|
isHomepageFirstModule={isHomepageFirstModule}
|
|
54
56
|
showAffiliateDisclaimer={showAffiliateDisclaimer}
|
|
57
|
+
showIcon={showIcon}
|
|
58
|
+
icon={icon}
|
|
55
59
|
>
|
|
56
60
|
{content}
|
|
57
61
|
</Tabs>
|
|
@@ -91,6 +95,8 @@ TopList.propTypes = {
|
|
|
91
95
|
page: PropTypes.shape({ template: PropTypes.string, path: PropTypes.string }),
|
|
92
96
|
showAffiliateDisclaimer: PropTypes.bool,
|
|
93
97
|
verifyIcon: PropTypes.string,
|
|
98
|
+
showIcon: PropTypes.string,
|
|
99
|
+
icon: PropTypes.func,
|
|
94
100
|
};
|
|
95
101
|
|
|
96
102
|
export default TopList;
|
|
@@ -20,6 +20,10 @@ const Tabs = ({
|
|
|
20
20
|
moduleStyle,
|
|
21
21
|
isHomepageFirstModule = false,
|
|
22
22
|
showAffiliateDisclaimer = false,
|
|
23
|
+
showIcon = false,
|
|
24
|
+
icon = null,
|
|
25
|
+
showNumberOfResults = false,
|
|
26
|
+
totalResults,
|
|
23
27
|
}) => {
|
|
24
28
|
const showAllTabId = `${showAll}_0`;
|
|
25
29
|
const [activeTab, setActiveTab] = useState(
|
|
@@ -64,6 +68,10 @@ const Tabs = ({
|
|
|
64
68
|
alignRight={tabsAlign === 'right'}
|
|
65
69
|
module={module}
|
|
66
70
|
gtmClass={gtmClass}
|
|
71
|
+
showIcon={showIcon}
|
|
72
|
+
icon={icon}
|
|
73
|
+
showNumberOfResults={showNumberOfResults}
|
|
74
|
+
totalResults={totalResults}
|
|
67
75
|
/>
|
|
68
76
|
)}
|
|
69
77
|
{showAffiliateDisclaimer && <AffiliateDisclaimer className={styles.disclaimer || ''} />}
|
|
@@ -106,6 +114,10 @@ Tabs.propTypes = {
|
|
|
106
114
|
moduleStyle: PropTypes.string,
|
|
107
115
|
isHomepageFirstModule: PropTypes.bool,
|
|
108
116
|
showAffiliateDisclaimer: PropTypes.bool,
|
|
117
|
+
showIcon: PropTypes.bool,
|
|
118
|
+
icon: PropTypes.func,
|
|
119
|
+
showNumberOfResults: PropTypes.bool,
|
|
120
|
+
totalResults: PropTypes.number,
|
|
109
121
|
};
|
|
110
122
|
|
|
111
123
|
export default Tabs;
|
|
@@ -16,12 +16,19 @@ const TabList = ({
|
|
|
16
16
|
showAll,
|
|
17
17
|
alignRight = false,
|
|
18
18
|
gtmClass = '',
|
|
19
|
+
showIcon = false,
|
|
20
|
+
icon = null,
|
|
21
|
+
showNumberOfResults = false,
|
|
22
|
+
totalResults,
|
|
19
23
|
}) => {
|
|
20
24
|
const filterBtn = useRef(null);
|
|
21
25
|
const tabList = useRef(null);
|
|
22
26
|
|
|
23
27
|
const tabItems = showAll
|
|
24
|
-
? [
|
|
28
|
+
? [
|
|
29
|
+
<div results={totalResults} label={showAll} tabId={`${showAll}_0`} key={keygen()} />,
|
|
30
|
+
...items,
|
|
31
|
+
]
|
|
25
32
|
: items;
|
|
26
33
|
|
|
27
34
|
function showDropdown() {
|
|
@@ -44,7 +51,7 @@ const TabList = ({
|
|
|
44
51
|
<ol ref={tabList} className={styles?.list || ''} data-id="select-list">
|
|
45
52
|
{tabItems.map((item, index) => {
|
|
46
53
|
if (item === null) return null;
|
|
47
|
-
const { label } = item.props;
|
|
54
|
+
const { label, results } = item.props;
|
|
48
55
|
return (
|
|
49
56
|
<Tab
|
|
50
57
|
activeTab={activeTab}
|
|
@@ -55,6 +62,10 @@ const TabList = ({
|
|
|
55
62
|
onClick={onClick}
|
|
56
63
|
toggleDropdown={showDropdown}
|
|
57
64
|
gtmClass={gtmClass}
|
|
65
|
+
showIcon={showIcon}
|
|
66
|
+
icon={icon}
|
|
67
|
+
showResults={showNumberOfResults}
|
|
68
|
+
results={results}
|
|
58
69
|
/>
|
|
59
70
|
);
|
|
60
71
|
})}
|
|
@@ -71,6 +82,10 @@ TabList.propTypes = {
|
|
|
71
82
|
activeTabClass: PropTypes.string,
|
|
72
83
|
alignRight: PropTypes.bool,
|
|
73
84
|
gtmClass: PropTypes.string,
|
|
85
|
+
showIcon: PropTypes.string,
|
|
86
|
+
icon: PropTypes.func,
|
|
87
|
+
showNumberOfResults: PropTypes.bool,
|
|
88
|
+
totalResults: PropTypes.number,
|
|
74
89
|
};
|
|
75
90
|
|
|
76
91
|
export default TabList;
|
|
@@ -12,6 +12,9 @@ const Tab = ({
|
|
|
12
12
|
tabId,
|
|
13
13
|
toggleDropdown,
|
|
14
14
|
gtmClass = '',
|
|
15
|
+
showResults = false,
|
|
16
|
+
results,
|
|
17
|
+
showIcon = false,
|
|
15
18
|
icon = null,
|
|
16
19
|
}) => {
|
|
17
20
|
let className = '';
|
|
@@ -35,7 +38,8 @@ const Tab = ({
|
|
|
35
38
|
}}
|
|
36
39
|
>
|
|
37
40
|
{label}
|
|
38
|
-
{
|
|
41
|
+
{showResults && <span>{results}</span>}
|
|
42
|
+
{showIcon && icon}
|
|
39
43
|
</button>
|
|
40
44
|
</li>
|
|
41
45
|
);
|
|
@@ -48,6 +52,9 @@ Tab.propTypes = {
|
|
|
48
52
|
tabId: PropTypes.string,
|
|
49
53
|
label: PropTypes.string,
|
|
50
54
|
gtmClass: PropTypes.string,
|
|
55
|
+
showIcon: PropTypes.bool,
|
|
56
|
+
showResults: PropTypes.bool,
|
|
57
|
+
results: PropTypes.number,
|
|
51
58
|
icon: PropTypes.func,
|
|
52
59
|
};
|
|
53
60
|
|