gatsby-core-theme 44.4.52 → 44.5.0-poc.1
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/.ci.yml +26 -0
- package/CHANGELOG.md +27 -130
- package/gatsby-browser.js +90 -48
- package/gatsby-node.mjs +21 -25
- package/package.json +1 -1
- package/release.config.js +5 -0
- package/src/components/atoms/author/index.js +5 -6
- package/src/components/atoms/collapse/collapse.test.js +26 -113
- package/src/components/atoms/collapse/index.js +1 -23
- package/src/components/molecules/comment/comment.module.scss +57 -7
- package/src/components/molecules/comment/index.js +79 -5
- package/src/components/molecules/header/variants/operator/template-one-two/index.js +3 -4
- package/src/components/molecules/header/variants/operator/template-one-two/template-one-two.stories.js +3 -4
- package/src/components/molecules/header/variants/slot/template-one/index.js +3 -4
- package/src/components/molecules/header/variants/slot/template-one/template-one.stories.js +3 -4
- package/src/components/molecules/leave-comment-form/index.js +0 -1
- package/src/components/organisms/anchor/template-one/anchor.module.scss +11 -19
- package/src/components/organisms/archive/index.js +2 -5
- package/src/components/organisms/comments/comment-tree/index.js +7 -8
- package/src/components/organisms/comments/index.js +24 -13
- package/src/components/organisms/cookie-consent/index.js +34 -48
- package/src/components/organisms/form/fields/fields.module.scss +2 -5
- package/src/components/organisms/form/fields/index.js +4 -2
- package/src/components/organisms/form/form.module.scss +39 -76
- package/src/components/organisms/form/index.js +1 -0
- package/src/constants/forms.js +1 -1
- package/src/helpers/tracker.mjs +2 -2
- package/src/resolver/redirect.mjs +0 -23
- package/src/resolver/redirect.test.js +1 -65
- package/src/components/atoms/comment-votes/comment-votes.module.scss +0 -34
- package/src/components/atoms/comment-votes/index.js +0 -92
- package/src/components/organisms/comments/comment-tree/comment-tree.module.scss +0 -47
- package/src/context/VotesProvider.js +0 -49
package/.ci.yml
CHANGED
|
@@ -49,6 +49,8 @@ Theme Beta Publish:
|
|
|
49
49
|
tags:
|
|
50
50
|
- gatsby-runner-dev-docker
|
|
51
51
|
before_script:
|
|
52
|
+
- echo "@gigmedia:registry=https://registry.npmjs.org/" >> ~/.npmrc
|
|
53
|
+
- echo "//registry.npmjs.org/:_authToken=${NPM_AUTH_TOKEN}" >> ~/.npmrc
|
|
52
54
|
- git config --global http.sslverify false
|
|
53
55
|
- git config --global user.email "floyd@gig.com"
|
|
54
56
|
- git config --global user.name "floyd"
|
|
@@ -64,3 +66,27 @@ Theme Beta Publish:
|
|
|
64
66
|
- beta
|
|
65
67
|
variables:
|
|
66
68
|
- $PIPELINE != "content-trigger"
|
|
69
|
+
|
|
70
|
+
Theme POC Publish:
|
|
71
|
+
image: node:18.17.0
|
|
72
|
+
stage: publish-poc
|
|
73
|
+
tags:
|
|
74
|
+
- gatsby-runner-dev-docker
|
|
75
|
+
before_script:
|
|
76
|
+
- echo "@gigmedia:registry=https://registry.npmjs.org/" >> ~/.npmrc
|
|
77
|
+
- echo "//registry.npmjs.org/:_authToken=${NPM_AUTH_TOKEN}" >> ~/.npmrc
|
|
78
|
+
- git config --global http.sslverify false
|
|
79
|
+
- git config --global user.email "floyd@gig.com"
|
|
80
|
+
- git config --global user.name "floyd"
|
|
81
|
+
script:
|
|
82
|
+
- export HUSKY=0
|
|
83
|
+
- yarn config set cache-folder .yarn
|
|
84
|
+
- yarn
|
|
85
|
+
- cd gatsby-theme/
|
|
86
|
+
- npx semantic-release@22.0.0
|
|
87
|
+
when: manual
|
|
88
|
+
only:
|
|
89
|
+
refs:
|
|
90
|
+
- poc
|
|
91
|
+
variables:
|
|
92
|
+
- $PIPELINE != "content-trigger"
|
package/CHANGELOG.md
CHANGED
|
@@ -1,153 +1,50 @@
|
|
|
1
|
-
|
|
1
|
+
# [44.5.0-poc.1](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.35-poc.2...v44.5.0-poc.1) (2025-09-04)
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
### Bug Fixes
|
|
5
5
|
|
|
6
|
-
*
|
|
6
|
+
* deploy fix ([42e33b3](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/42e33b3a434cde10e899afef41852dff49fe9700))
|
|
7
|
+
* gtm id ([52c86e7](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/52c86e77884fc12da1db4f1aea6ef739d44d224b))
|
|
8
|
+
* test deploy ([fa38562](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/fa3856257c8149dc84bf72e57e0fcc5ece8839af))
|
|
9
|
+
* test deploy ([6d649ce](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/6d649ce3343a61792522be16a792fcc2c7aa158d))
|
|
10
|
+
* yield only on one place ([52acd92](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/52acd92131461b781f1b8e60e9f366239878ca3e))
|
|
7
11
|
|
|
8
|
-
## [44.4.51](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.50...v44.4.51) (2025-09-02)
|
|
9
12
|
|
|
13
|
+
* Merge branch 'poc' of gitlab.com:g2m-gentoo/team-floyd/themes/gatsby-themes into poc ([cb72402](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/cb72402d1e34e427742f6ae335f77bbb9ad77785))
|
|
14
|
+
* Merge branch 'revert-2a55f352' into 'poc' ([eb0069c](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/eb0069cd14b7a01c85e911cf6bf4abf8b4bb0fce))
|
|
15
|
+
* Revert "fix: remove multiple templates" ([0e1a8ca](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/0e1a8ca0d1f7d21d059eff734aa040ef02f0e9b9))
|
|
10
16
|
|
|
11
|
-
### Bug Fixes
|
|
12
|
-
|
|
13
|
-
* testing gtm scripts ([9fc6ffb](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/9fc6ffbcd00472155df82315dffa42a093a0cec7))
|
|
14
|
-
|
|
15
|
-
## [44.4.50](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.49...v44.4.50) (2025-09-02)
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
### Bug Fixes
|
|
19
|
-
|
|
20
|
-
* testing INP ([397a9cd](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/397a9cda61065a81b9d596a07679a722e534d788))
|
|
21
|
-
|
|
22
|
-
## [44.4.49](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.48...v44.4.49) (2025-09-02)
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
### Bug Fixes
|
|
26
|
-
|
|
27
|
-
* updated gtm inclusion ([b7f0360](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/b7f03605d1984351042fa06a1cd67812d39e435e))
|
|
28
|
-
|
|
29
|
-
## [44.4.48](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.47...v44.4.48) (2025-09-02)
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
### Bug Fixes
|
|
33
|
-
|
|
34
|
-
* add lazy for comoponents ([732fdf7](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/732fdf7c10c3bbd1e46ca1d2f4bef04d879c8409))
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
* Merge branch 'en-8-cwv-unused-js' into 'master' ([bcc5448](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/bcc5448cfce871e8189c7fbd42493c6f1d4c477e))
|
|
38
|
-
|
|
39
|
-
## [44.4.47](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.46...v44.4.47) (2025-09-01)
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
### Bug Fixes
|
|
43
|
-
|
|
44
|
-
* checkbox issue ([dac5349](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/dac5349111ebd0c38bf1d84f05a35f34280dfe31))
|
|
45
|
-
|
|
46
|
-
## [44.4.46](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.45...v44.4.46) (2025-09-01)
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
### Bug Fixes
|
|
50
|
-
|
|
51
|
-
* comment vote logic ([a09a3bd](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/a09a3bd5ef047976362b12099fb37e84c682cb69))
|
|
52
|
-
|
|
53
|
-
## [44.4.45](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.44...v44.4.45) (2025-08-29)
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
### Bug Fixes
|
|
57
|
-
|
|
58
|
-
* voting logic ([15a7af0](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/15a7af00ac73f71837d083c913d83fb9d6c95ca9))
|
|
59
|
-
|
|
60
|
-
## [44.4.44](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.43...v44.4.44) (2025-08-29)
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
### Bug Fixes
|
|
64
|
-
|
|
65
|
-
* bug ([47ff70b](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/47ff70b136bbcbd7efe441637dbd28d5ff0a3818))
|
|
66
|
-
* bug ([2c76971](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/2c76971d6dca396f1c793786e9907d84f7b8fc15))
|
|
67
|
-
* styling fixes ([da45e7d](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/da45e7d745c79953f5f2d830d0c7c86c8a72f4a6))
|
|
68
17
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
### Bug Fixes
|
|
73
|
-
|
|
74
|
-
* voting ([2c38c8f](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/2c38c8ff3e2ee8b9aadeceb2e2318b47359d11b5))
|
|
75
|
-
|
|
76
|
-
## [44.4.42](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.41...v44.4.42) (2025-08-29)
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
### Bug Fixes
|
|
80
|
-
|
|
81
|
-
* outside click ([8b88022](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/8b88022dafe14a4c7c7d3d8efe08207a76659724))
|
|
82
|
-
* test collapse ([a5dc747](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/a5dc7471eae5df4ab4b3eda3e91856a2e728476c))
|
|
83
|
-
* test coverage ([bbd1138](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/bbd1138c1c668e745923917ddc5b08c5d994f64d))
|
|
84
|
-
* test outside click ([c616f66](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/c616f66192927bc53366f5ede49827614dcdf847))
|
|
85
|
-
* voting ([2f2eb5c](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/2f2eb5c696d96c591af536a81f45bc7d4484e632))
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
* Merge branch 'collapse-outside-click' into 'master' ([ade0483](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/ade0483aef0a470638e1b3132e11c850db0662b2))
|
|
89
|
-
|
|
90
|
-
## [44.4.41](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.40...v44.4.41) (2025-08-28)
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
### Bug Fixes
|
|
94
|
-
|
|
95
|
-
* removed logs ([8930faa](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/8930faa83e1561dfb9c9bbb993fc167a2527363a))
|
|
96
|
-
|
|
97
|
-
## [44.4.40](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.39...v44.4.40) (2025-08-28)
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
### Bug Fixes
|
|
101
|
-
|
|
102
|
-
* changed limit of chars ([c1649bf](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/c1649bf408e3f14bbb070f2988306d5e84ba15a2))
|
|
103
|
-
* test ([0d6646b](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/0d6646be600d5c977b8f0c4ee90ab4326f604eed))
|
|
104
|
-
* update env ([849fc61](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/849fc61d6f0f33b2be2c2336061344b4a39c6f91))
|
|
105
|
-
|
|
106
|
-
## [44.4.39](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.38...v44.4.39) (2025-08-26)
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
### Bug Fixes
|
|
110
|
-
|
|
111
|
-
* env handling ([149b8f2](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/149b8f2de79af7532ce434223d12ef9249ba2047))
|
|
112
|
-
|
|
113
|
-
## [44.4.38](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.37...v44.4.38) (2025-08-26)
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
### Bug Fixes
|
|
117
|
-
|
|
118
|
-
* redirect logic for affiliates ([f88bc07](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/f88bc07ac8e48f90cc25c57ddecb75eed774a284))
|
|
119
|
-
* redirects ([c6ba3a0](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/c6ba3a00e7a794e7d7d816611bc72ae4531bf4ce))
|
|
120
|
-
* redirects ([c8358be](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/c8358be986550b149677e7ec0eee484db913120e))
|
|
121
|
-
* tests ([9e90c50](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/9e90c50ef0a77ae246033225f111a3ecc6d5f302))
|
|
122
|
-
|
|
123
|
-
## [44.4.37](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.36...v44.4.37) (2025-08-25)
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
### Bug Fixes
|
|
18
|
+
### Features
|
|
127
19
|
|
|
128
|
-
*
|
|
129
|
-
* test ([7630b92](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/7630b92b621e6117c400af243d2b4c300422a833))
|
|
130
|
-
* test ([385538b](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/385538b233d94cb8416f31eedd5f509efa1d1c1e))
|
|
20
|
+
* yield scripts and gtm crossOrigin ([88858d5](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/88858d558d516f267cce68056a43513c18248ba6))
|
|
131
21
|
|
|
132
|
-
## [44.4.
|
|
22
|
+
## [44.4.35-poc.2](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.35-poc.1...v44.4.35-poc.2) (2025-09-01)
|
|
133
23
|
|
|
134
24
|
|
|
135
25
|
### Bug Fixes
|
|
136
26
|
|
|
137
|
-
*
|
|
138
|
-
* added env var to enable server redirects instead of splash screens ([c67368f](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/c67368f1f11184ba52d2a32ea35e78e53e79b1a4))
|
|
139
|
-
* updated env ([dde7f3b](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/dde7f3b11987fa88f018bd69b96b8ca4db1765d8))
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
* Merge branch 'tm-5657-redirect-logic' into 'master' ([04f2c5b](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/04f2c5b863246c0889f232d65a7c375ea8e417d4))
|
|
143
|
-
* Merge branch 'tm-5331-load-more-archive' into 'master' ([22da05c](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/22da05cf57b9bc77fe5f37bb5fc955ad7ec9351e))
|
|
27
|
+
* remove multiple templates ([2a55f35](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/2a55f3521f55a51f11200b098abec0e978f7ecfa))
|
|
144
28
|
|
|
145
|
-
## [44.4.35](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.34...v44.4.35) (2025-08-
|
|
29
|
+
## [44.4.35-poc.1](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.34...v44.4.35-poc.1) (2025-08-22)
|
|
146
30
|
|
|
147
31
|
|
|
148
32
|
### Bug Fixes
|
|
149
33
|
|
|
34
|
+
* added commit pipelines ([0d583de](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/0d583de2d5683794918c6bb89e59a2a7ab88848f))
|
|
35
|
+
* added stage ci cd ([9fa7040](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/9fa7040c89379832385b0d0a0fb4830c093601fa))
|
|
36
|
+
* added utils to publush script ([2c78e6e](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/2c78e6e276e034739b8fb08228ad637cf8a96122))
|
|
150
37
|
* added validation to comments ([64cd409](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/64cd40908393328d83fa10d933b834b74b418894))
|
|
38
|
+
* ci cd ([86d0f72](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/86d0f725b51853c019d4c492136e525b29d50285))
|
|
39
|
+
* deploy pm2 name ([0574aa7](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/0574aa77c25be5eda6a8f5131965ad36680d3152))
|
|
40
|
+
* deploy pm2 name ([70fbbe7](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/70fbbe7026b584967bffcb9b3d169150e834a9fd))
|
|
41
|
+
* deploy pm2 name ([e937f5f](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/e937f5f9183d9f050211079a65b6c22b8e3c7f32))
|
|
42
|
+
* deploy pm2 name ([a384b54](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/a384b545c3112742c9d9126cac655aa20a2aadbc))
|
|
43
|
+
* deploy pm2 name ([ef636b1](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/ef636b125cccc81158298bd0a2ca3f3c2e9be2ed))
|
|
44
|
+
* deploy pm2 name ([24662d5](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/24662d5464dd6227da04c25c9a4a07ce2ab4fbfc))
|
|
45
|
+
* pm2 name ([9c26e31](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/9c26e3103a4f01313a2aa67812eaa699e6fb6ddd))
|
|
46
|
+
* poc stages added ([502f386](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/502f386fe8f7a9444daab822e798db48a5873a1b))
|
|
47
|
+
* semantic release ([ccc3375](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/ccc3375e46d8c563cd62f6268c61c6d6394f6676))
|
|
151
48
|
* tnc validation ([f4bb891](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/f4bb8914e4f73e8f33952df2209f212ca677cafb))
|
|
152
49
|
|
|
153
50
|
## [44.4.34](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.4.33...v44.4.34) (2025-08-21)
|
package/gatsby-browser.js
CHANGED
|
@@ -9,42 +9,58 @@
|
|
|
9
9
|
/* eslint-disable prefer-destructuring */
|
|
10
10
|
|
|
11
11
|
// Main Vars
|
|
12
|
-
require(
|
|
13
|
-
require(
|
|
14
|
-
require(
|
|
15
|
-
require(
|
|
16
|
-
require(
|
|
17
|
-
require(
|
|
12
|
+
require("./src/styles/utils/variables/_colors.scss");
|
|
13
|
+
require("./src/styles/utils/variables/_main.scss");
|
|
14
|
+
require("./src/styles/base/_typography.scss");
|
|
15
|
+
require("./src/styles/base/_reset.scss");
|
|
16
|
+
require("./src/styles/base/_spacing.scss");
|
|
17
|
+
require("./src/styles/layouts/_grid.scss");
|
|
18
|
+
|
|
19
|
+
async function yieldToMain() {
|
|
20
|
+
if (globalThis.scheduler?.yield) {
|
|
21
|
+
return scheduler.yield();
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
// Fall back to yielding with setTimeout.
|
|
25
|
+
return new Promise((resolve) => {
|
|
26
|
+
setTimeout(resolve, 0);
|
|
27
|
+
});
|
|
28
|
+
}
|
|
18
29
|
|
|
19
30
|
function initGTM() {
|
|
20
|
-
if (
|
|
31
|
+
if (
|
|
32
|
+
window.loadGTM === false ||
|
|
33
|
+
window.gtmDidInit ||
|
|
34
|
+
process.env.DISABLE_GTM === "true"
|
|
35
|
+
) {
|
|
21
36
|
return false;
|
|
22
37
|
}
|
|
23
38
|
|
|
24
39
|
window.gtmDidInit = true; // flag to ensure script does not get added to DOM more than once.
|
|
25
40
|
const trackingLink = `https://www.googletagmanager.com/gtm.js?id=${process.env.GA_TRACKING_ID}`;
|
|
26
41
|
|
|
27
|
-
const script = document.createElement(
|
|
28
|
-
script.type =
|
|
42
|
+
const script = document.createElement("script");
|
|
43
|
+
script.type = "text/javascript";
|
|
29
44
|
script.async = true;
|
|
45
|
+
script.crossOrigin = "anonymous";
|
|
30
46
|
script.src = trackingLink;
|
|
31
47
|
|
|
32
48
|
script.onload = () => {
|
|
33
49
|
// eslint-disable-next-line no-undef
|
|
34
50
|
dataLayer.push({
|
|
35
51
|
// ensure PageViews are always tracked
|
|
36
|
-
event:
|
|
37
|
-
|
|
38
|
-
|
|
52
|
+
event: "gtm.js",
|
|
53
|
+
"gtm.start": new Date().getTime(),
|
|
54
|
+
"gtm.uniqueEventId": 0,
|
|
39
55
|
});
|
|
40
56
|
};
|
|
41
57
|
document.head.appendChild(script);
|
|
42
58
|
|
|
43
|
-
const noscript = document.createElement(
|
|
44
|
-
const iframe = document.createElement(
|
|
59
|
+
const noscript = document.createElement("noscript");
|
|
60
|
+
const iframe = document.createElement("iframe");
|
|
45
61
|
iframe.src = trackingLink;
|
|
46
|
-
iframe.style.display =
|
|
47
|
-
iframe.style.visibility =
|
|
62
|
+
iframe.style.display = "none";
|
|
63
|
+
iframe.style.visibility = "hidden";
|
|
48
64
|
iframe.height = 0;
|
|
49
65
|
iframe.width = 0;
|
|
50
66
|
noscript.innerHTML += iframe.outerHTML;
|
|
@@ -52,16 +68,15 @@ function initGTM() {
|
|
|
52
68
|
}
|
|
53
69
|
|
|
54
70
|
function optinMonster() {
|
|
55
|
-
const script = document.createElement(
|
|
56
|
-
script.id =
|
|
57
|
-
script.setAttribute(
|
|
58
|
-
script.setAttribute(
|
|
59
|
-
script.src =
|
|
71
|
+
const script = document.createElement("script");
|
|
72
|
+
script.id = "optin-monstr";
|
|
73
|
+
script.setAttribute("data-user", process.env.OPTINMONSTR_USER);
|
|
74
|
+
script.setAttribute("data-account", process.env.OPTINMONSTR_ACC);
|
|
75
|
+
script.src = "https://a.omappapi.com/app/js/api.min.js";
|
|
60
76
|
script.async = true;
|
|
61
77
|
document.head.appendChild(script);
|
|
62
78
|
}
|
|
63
79
|
|
|
64
|
-
|
|
65
80
|
const loadFacebookPixel = () => {
|
|
66
81
|
!(function (f, b, e, v, n, t, s) {
|
|
67
82
|
// eslint-disable-next-line no-multi-assign
|
|
@@ -75,15 +90,20 @@ const loadFacebookPixel = () => {
|
|
|
75
90
|
if (!f._fbq) f._fbq = n;
|
|
76
91
|
n.push = n;
|
|
77
92
|
n.loaded = !0;
|
|
78
|
-
n.version =
|
|
93
|
+
n.version = "2.0";
|
|
79
94
|
n.queue = [];
|
|
80
95
|
t = b.createElement(e);
|
|
81
96
|
t.async = !0;
|
|
82
|
-
t.id =
|
|
97
|
+
t.id = "pixel-code";
|
|
83
98
|
t.src = v;
|
|
84
99
|
s = b.getElementsByTagName(e)[0];
|
|
85
100
|
s.parentNode.insertBefore(t, s);
|
|
86
|
-
})(
|
|
101
|
+
})(
|
|
102
|
+
window,
|
|
103
|
+
document,
|
|
104
|
+
"script",
|
|
105
|
+
"https://connect.facebook.net/en_US/fbevents.js"
|
|
106
|
+
);
|
|
87
107
|
};
|
|
88
108
|
|
|
89
109
|
const microsoftAdvertising = () => {
|
|
@@ -91,73 +111,95 @@ const microsoftAdvertising = () => {
|
|
|
91
111
|
var f, n, i;
|
|
92
112
|
(w[u] = w[u] || []),
|
|
93
113
|
(f = function () {
|
|
94
|
-
var o = { ti:
|
|
95
|
-
(o.q = w[u]), (w[u] = new UET(o)), w[u].push(
|
|
114
|
+
var o = { ti: "187106455", enableAutoSpaTracking: true };
|
|
115
|
+
(o.q = w[u]), (w[u] = new UET(o)), w[u].push("pageLoad");
|
|
96
116
|
}),
|
|
97
117
|
(n = d.createElement(t)),
|
|
98
118
|
(n.src = r),
|
|
99
119
|
(n.async = 1),
|
|
100
|
-
(n.id =
|
|
120
|
+
(n.id = "microsoft-code"),
|
|
101
121
|
(n.onload = n.onreadystatechange =
|
|
102
122
|
function () {
|
|
103
123
|
var s = this.readyState;
|
|
104
|
-
(s && s !==
|
|
124
|
+
(s && s !== "loaded" && s !== "complete") ||
|
|
105
125
|
(f(), (n.onload = n.onreadystatechange = null));
|
|
106
126
|
}),
|
|
107
127
|
(i = d.getElementsByTagName(t)[0]),
|
|
108
128
|
i.parentNode.insertBefore(n, i);
|
|
109
|
-
})(window, document,
|
|
129
|
+
})(window, document, "script", "//bat.bing.com/bat.js", "uetq");
|
|
110
130
|
};
|
|
111
131
|
|
|
112
|
-
const piguard = () =>{
|
|
132
|
+
const piguard = () => {
|
|
113
133
|
if (window.loadGTM === false) {
|
|
114
134
|
return false;
|
|
115
135
|
}
|
|
116
136
|
|
|
117
|
-
const script = document.createElement(
|
|
118
|
-
script.id =
|
|
137
|
+
const script = document.createElement("script");
|
|
138
|
+
script.id = "piguard";
|
|
119
139
|
script.src = `https://pg.${process.env.GATSBY_SITE_NAME}/analytics.js?tid=PP-${process.env.PIGUARD_ID}`;
|
|
120
140
|
script.async = true;
|
|
121
141
|
document.head.appendChild(script);
|
|
122
|
-
}
|
|
142
|
+
};
|
|
123
143
|
|
|
124
|
-
function scrollEvent(event) {
|
|
144
|
+
async function scrollEvent(event) {
|
|
145
|
+
await yieldToMain();
|
|
125
146
|
initGTM();
|
|
126
|
-
|
|
127
|
-
|
|
147
|
+
if (
|
|
148
|
+
!document.getElementById("piguard") &&
|
|
149
|
+
process.env.ENABLE_PIGUARD === "true"
|
|
150
|
+
) {
|
|
128
151
|
piguard();
|
|
129
152
|
}
|
|
130
153
|
|
|
131
|
-
if (
|
|
154
|
+
if (
|
|
155
|
+
process.env.ENABLE_MICROSOFT === "true" &&
|
|
156
|
+
!document.getElementById("microsoft-code")
|
|
157
|
+
)
|
|
132
158
|
microsoftAdvertising();
|
|
133
159
|
|
|
134
|
-
if (
|
|
160
|
+
if (
|
|
161
|
+
process.env.ENABLE_OPTINMONSTR === "true" &&
|
|
162
|
+
!document.getElementById("optin-monstr")
|
|
163
|
+
)
|
|
135
164
|
optinMonster();
|
|
136
|
-
if (
|
|
165
|
+
if (
|
|
166
|
+
process.env.ENABLE_PIXEL === "true" &&
|
|
167
|
+
!document.getElementById("pixel-code")
|
|
168
|
+
) {
|
|
137
169
|
if (
|
|
138
|
-
typeof window !==
|
|
170
|
+
typeof window !== "undefined" &&
|
|
139
171
|
window.location.pathname !== process.env.PAGE_EXCLUDE_PIXEL
|
|
140
172
|
) {
|
|
141
173
|
loadFacebookPixel();
|
|
142
174
|
|
|
143
|
-
fbq(
|
|
175
|
+
fbq("init", process.env.PIXEL_ID);
|
|
144
176
|
|
|
145
177
|
// Initialize and track the PageView event
|
|
146
|
-
fbq(
|
|
178
|
+
fbq("track", "PageView");
|
|
147
179
|
}
|
|
148
180
|
}
|
|
149
181
|
|
|
150
182
|
if (event) {
|
|
151
|
-
event.currentTarget
|
|
183
|
+
event.currentTarget?.removeEventListener(event.type, scrollEvent); // remove the event listener that got triggered
|
|
152
184
|
}
|
|
153
185
|
}
|
|
154
186
|
|
|
155
187
|
exports.onClientEntry = () => {
|
|
156
|
-
if (process.env.PPC ===
|
|
188
|
+
if (process.env.PPC === "true") {
|
|
157
189
|
scrollEvent(null);
|
|
158
190
|
} else {
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
191
|
+
// detect if is mobile
|
|
192
|
+
if (
|
|
193
|
+
/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(
|
|
194
|
+
navigator.userAgent
|
|
195
|
+
)
|
|
196
|
+
) {
|
|
197
|
+
scrollEvent(null);
|
|
198
|
+
return;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
document.addEventListener("scroll", scrollEvent);
|
|
202
|
+
document.addEventListener("mousemove", scrollEvent);
|
|
203
|
+
document.addEventListener("touchstart", scrollEvent, { passive: true });
|
|
162
204
|
}
|
|
163
205
|
};
|
package/gatsby-node.mjs
CHANGED
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
clean,
|
|
24
24
|
removeUnwantedSections,
|
|
25
25
|
} from "./src/resolver/common.mjs";
|
|
26
|
-
import { generateRedirects
|
|
26
|
+
import { generateRedirects } from "./src/resolver/redirect.mjs";
|
|
27
27
|
import { translate, is404Page } from "./src/helpers/getters.mjs";
|
|
28
28
|
import { getArchivePages, hasArchiveModule } from "./src/resolver/archive.mjs";
|
|
29
29
|
|
|
@@ -71,10 +71,12 @@ const relations = {};
|
|
|
71
71
|
|
|
72
72
|
// eslint-disable-next-line import/prefer-default-export
|
|
73
73
|
export const createPages = async (
|
|
74
|
-
{ actions: { createPage
|
|
74
|
+
{ actions: { createPage } },
|
|
75
75
|
themeOptions
|
|
76
76
|
) => {
|
|
77
77
|
process.env.GATSBY_SITE_NAME = String(themeOptions.siteName);
|
|
78
|
+
|
|
79
|
+
generateRedirects(siteSettingsData);
|
|
78
80
|
preconnectLinks = themeOptions.preconnectLinks || [];
|
|
79
81
|
console.log(chalk.magenta("info") + chalk.whiteBright(" starting processor"));
|
|
80
82
|
|
|
@@ -124,8 +126,6 @@ export const createPages = async (
|
|
|
124
126
|
streamRobotsTxt.write(robotsTxtContent);
|
|
125
127
|
streamRobotsTxt.end();
|
|
126
128
|
|
|
127
|
-
generateRedirects(siteSettingsData);
|
|
128
|
-
|
|
129
129
|
// create every single page
|
|
130
130
|
Object.keys(processed.site_markets).forEach((siteMarket) => {
|
|
131
131
|
if (!processed.pages[siteMarket]["page"]) {
|
|
@@ -282,27 +282,23 @@ export const createPages = async (
|
|
|
282
282
|
}
|
|
283
283
|
});
|
|
284
284
|
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
},
|
|
303
|
-
});
|
|
304
|
-
})
|
|
305
|
-
}
|
|
285
|
+
trackingPages.forEach(({ path, page, operator }) => {
|
|
286
|
+
createPage({
|
|
287
|
+
path,
|
|
288
|
+
component: `${__dirname}/src/components/${
|
|
289
|
+
process.env.IS_TRACKING_SSR === "true"
|
|
290
|
+
? "app-tracker-ssr.js"
|
|
291
|
+
: "app-tracker.js"
|
|
292
|
+
}`,
|
|
293
|
+
context: {
|
|
294
|
+
page,
|
|
295
|
+
siteGeneralData,
|
|
296
|
+
operator,
|
|
297
|
+
isTracker: true,
|
|
298
|
+
isLiveStreamProvider: false,
|
|
299
|
+
},
|
|
300
|
+
});
|
|
301
|
+
});
|
|
306
302
|
};
|
|
307
303
|
|
|
308
304
|
export const onCreatePage = async ({ page, actions }) => {
|
package/package.json
CHANGED
package/release.config.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/* eslint-disable react-hooks/rules-of-hooks */
|
|
2
2
|
/* eslint-disable arrow-body-style */
|
|
3
|
-
import React
|
|
3
|
+
import React from 'react';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
5
|
|
|
6
6
|
import { formatDate } from '~helpers/date-time';
|
|
@@ -8,11 +8,10 @@ import { imagePrettyUrl } from '~helpers/getters';
|
|
|
8
8
|
import Link from '~hooks/link';
|
|
9
9
|
import LazyImage from '~hooks/lazy-image';
|
|
10
10
|
import useTranslate from '~hooks/useTranslate/useTranslate';
|
|
11
|
+
import Verify from '~images/icons/verify';
|
|
12
|
+
import Clock from '~images/icons/clock';
|
|
11
13
|
import styles from './author.module.scss';
|
|
12
14
|
|
|
13
|
-
const VerifyIcon = lazy(() => import('~images/icons/verify'));
|
|
14
|
-
const ClockIcon = lazy(() => import('~images/icons/clock'));
|
|
15
|
-
|
|
16
15
|
const Author = ({
|
|
17
16
|
name,
|
|
18
17
|
date,
|
|
@@ -27,11 +26,11 @@ const Author = ({
|
|
|
27
26
|
isCardsAuthor = false,
|
|
28
27
|
hasAuthorBox = false,
|
|
29
28
|
reviewer,
|
|
30
|
-
clock = <
|
|
29
|
+
clock = <Clock />,
|
|
31
30
|
authorImageWidth = 30,
|
|
32
31
|
authorImageHeight = 30,
|
|
33
32
|
showVerification = false,
|
|
34
|
-
verifyIcon = <
|
|
33
|
+
verifyIcon = <Verify />,
|
|
35
34
|
}) => {
|
|
36
35
|
const prefixstyle = !link || !authorImg;
|
|
37
36
|
|