@eeacms/volto-clms-theme 1.1.160 → 1.1.162
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 +15 -0
- package/package.json +1 -1
- package/src/components/CLMSLoginView/CLMSLogin.jsx +4 -1
- package/src/customizations/volto/components/theme/Unauthorized/Unauthorized.jsx +6 -7
- package/src/customizations/volto/components/theme/Unauthorized/__snapshots__/Unauthorized.test.jsx.snap +8 -7
- package/src/customizations/volto/components/theme/Unauthorized/unauthorized-page.less +7 -0
- package/src/index.js +5 -0
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,21 @@ All notable changes to this project will be documented in this file. Dates are d
|
|
|
4
4
|
|
|
5
5
|
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
6
6
|
|
|
7
|
+
### [1.1.162](https://github.com/eea/volto-clms-theme/compare/1.1.161...1.1.162) - 26 June 2024
|
|
8
|
+
|
|
9
|
+
#### :hammer_and_wrench: Others
|
|
10
|
+
|
|
11
|
+
- Refs #271250 - Insert scripts on Error pages. [GhitaB - [`f35ff6a`](https://github.com/eea/volto-clms-theme/commit/f35ff6ac7125f09db73465e12314feaf7faea431)]
|
|
12
|
+
### [1.1.161](https://github.com/eea/volto-clms-theme/compare/1.1.160...1.1.161) - 25 June 2024
|
|
13
|
+
|
|
14
|
+
#### :hammer_and_wrench: Others
|
|
15
|
+
|
|
16
|
+
- Refs #271250 - Fix jenkins. [GhitaB - [`97abad7`](https://github.com/eea/volto-clms-theme/commit/97abad74f81f2322d5c14f8cd6aefb707d798fc1)]
|
|
17
|
+
- Refs #271250 - Fix jenkins. [GhitaB - [`e80bc5c`](https://github.com/eea/volto-clms-theme/commit/e80bc5cb0e62e24ba889cf17ba79f0eddf68ddba)]
|
|
18
|
+
- Refs #271250 - Fix jenkins. [GhitaB - [`74e2312`](https://github.com/eea/volto-clms-theme/commit/74e2312bc85974268a3779bdb2b7e88eff70a664)]
|
|
19
|
+
- Refs #271250 - Fix jenkins. [GhitaB - [`7f0f9dc`](https://github.com/eea/volto-clms-theme/commit/7f0f9dc40cfe3822fa1d6cd11718d4667238d9c2)]
|
|
20
|
+
- Refs #271250 - Unauthorized page: use login modal instead of link to login page. [GhitaB - [`e620559`](https://github.com/eea/volto-clms-theme/commit/e620559a83de9df5a6c6aa22ca4fbad4cde6d798)]
|
|
21
|
+
- Refs #271250 - Update Contact service helpdesk link in Login page. [GhitaB - [`8a1f765`](https://github.com/eea/volto-clms-theme/commit/8a1f765a3f25cf3677159f0f0d82be2a9769f9b0)]
|
|
7
22
|
### [1.1.160](https://github.com/eea/volto-clms-theme/compare/1.1.159...1.1.160) - 20 June 2024
|
|
8
23
|
|
|
9
24
|
#### :bug: Bug Fixes
|
package/package.json
CHANGED
|
@@ -73,7 +73,10 @@ function CLMSLoginView(props) {
|
|
|
73
73
|
</p>
|
|
74
74
|
<p>
|
|
75
75
|
If you have othe questions, please contact our
|
|
76
|
-
<UniversalLink
|
|
76
|
+
<UniversalLink
|
|
77
|
+
openLinkInNewTab
|
|
78
|
+
href="/en/contact-service-helpdesk"
|
|
79
|
+
>
|
|
77
80
|
{' '}
|
|
78
81
|
Service desk
|
|
79
82
|
</UniversalLink>
|
|
@@ -6,21 +6,22 @@ import { FormattedMessage } from 'react-intl';
|
|
|
6
6
|
import { useSelector } from 'react-redux';
|
|
7
7
|
import { Link } from 'react-router-dom';
|
|
8
8
|
import { Container } from 'semantic-ui-react';
|
|
9
|
-
import
|
|
9
|
+
import './unauthorized-page.less';
|
|
10
10
|
|
|
11
11
|
import { withServerErrorCode } from '@plone/volto/helpers/Utils/Utils';
|
|
12
|
-
|
|
12
|
+
import CclLoginModal from '@eeacms/volto-clms-theme/components/CclLoginModal/CclLoginModal';
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* unauthorized function.
|
|
16
16
|
* @function Unauthorized
|
|
17
17
|
* @returns {string} Markup of the unauthorized page.
|
|
18
18
|
*/
|
|
19
|
-
const Unauthorized = () => {
|
|
19
|
+
const Unauthorized = (props) => {
|
|
20
20
|
const error_message = useSelector((state) => state.apierror.message);
|
|
21
|
+
const { location = undefined } = props;
|
|
21
22
|
|
|
22
23
|
return (
|
|
23
|
-
<Container className="view-wrapper">
|
|
24
|
+
<Container className="view-wrapper unauthorized-page">
|
|
24
25
|
<h1>
|
|
25
26
|
<FormattedMessage id="Unauthorized" defaultMessage="Unauthorized" />
|
|
26
27
|
</h1>
|
|
@@ -30,9 +31,7 @@ const Unauthorized = () => {
|
|
|
30
31
|
id="You are trying to access a protected resource, please {login} first."
|
|
31
32
|
defaultMessage="You are trying to access a protected resource, please {login} first."
|
|
32
33
|
values={{
|
|
33
|
-
login:
|
|
34
|
-
<UniversalLink href="/en/login">Register/Login</UniversalLink>
|
|
35
|
-
),
|
|
34
|
+
login: <CclLoginModal otherPath={location?.pathname} />,
|
|
36
35
|
}}
|
|
37
36
|
/>
|
|
38
37
|
</p>
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
exports[`Unauthorized renders a not found component 1`] = `
|
|
4
4
|
<div
|
|
5
|
-
className="ui container view-wrapper"
|
|
5
|
+
className="ui container view-wrapper unauthorized-page"
|
|
6
6
|
>
|
|
7
7
|
<h1>
|
|
8
8
|
Unauthorized
|
|
@@ -14,15 +14,16 @@ exports[`Unauthorized renders a not found component 1`] = `
|
|
|
14
14
|
className="description"
|
|
15
15
|
>
|
|
16
16
|
You are trying to access a protected resource, please
|
|
17
|
-
<
|
|
18
|
-
className=
|
|
19
|
-
|
|
17
|
+
<span
|
|
18
|
+
className="header-login-link"
|
|
19
|
+
onBlur={[Function]}
|
|
20
20
|
onClick={[Function]}
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
onFocus={[Function]}
|
|
22
|
+
onMouseEnter={[Function]}
|
|
23
|
+
onMouseLeave={[Function]}
|
|
23
24
|
>
|
|
24
25
|
Register/Login
|
|
25
|
-
</
|
|
26
|
+
</span>
|
|
26
27
|
first.
|
|
27
28
|
</p>
|
|
28
29
|
<p>
|
package/src/index.js
CHANGED
|
@@ -224,6 +224,11 @@ const applyConfig = (config) => {
|
|
|
224
224
|
'footnote',
|
|
225
225
|
];
|
|
226
226
|
|
|
227
|
+
// Insert scripts on Error pages
|
|
228
|
+
if (config.settings?.serverConfig?.extractScripts) {
|
|
229
|
+
config.settings.serverConfig.extractScripts.errorPages = true;
|
|
230
|
+
}
|
|
231
|
+
|
|
227
232
|
config = installLinkEditor(config);
|
|
228
233
|
|
|
229
234
|
config.addonRoutes = [
|