@eeacms/volto-clms-theme 1.1.294 → 1.1.296
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
CHANGED
|
@@ -4,6 +4,20 @@ 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.296](https://github.com/eea/volto-clms-theme/compare/1.1.295...1.1.296) - 16 June 2026
|
|
8
|
+
|
|
9
|
+
#### :hammer_and_wrench: Others
|
|
10
|
+
|
|
11
|
+
- Refs #297796 - Fix ArrayWidget error to make related datasets field sortable. [GhitaB - [`b291165`](https://github.com/eea/volto-clms-theme/commit/b291165bf29a433cf9ed30aa9247fe161dd83bf4)]
|
|
12
|
+
### [1.1.295](https://github.com/eea/volto-clms-theme/compare/1.1.294...1.1.295) - 8 June 2026
|
|
13
|
+
|
|
14
|
+
#### :house: Internal changes
|
|
15
|
+
|
|
16
|
+
- style: Automated code fix [eea-jenkins - [`cb21bf3`](https://github.com/eea/volto-clms-theme/commit/cb21bf3e1891a59fce5e8cbd2bd2185ba67cae03)]
|
|
17
|
+
|
|
18
|
+
#### :hammer_and_wrench: Others
|
|
19
|
+
|
|
20
|
+
- fix routing [Dobricean Ioan Dorian - [`a640f1f`](https://github.com/eea/volto-clms-theme/commit/a640f1f55e682d2f6b5a007df8e12aa4283d27b1)]
|
|
7
21
|
### [1.1.294](https://github.com/eea/volto-clms-theme/compare/1.1.293...1.1.294) - 5 June 2026
|
|
8
22
|
|
|
9
23
|
#### :hammer_and_wrench: Others
|
package/package.json
CHANGED
|
@@ -299,14 +299,15 @@ class ArrayWidget extends Component {
|
|
|
299
299
|
!this.props.creatable
|
|
300
300
|
? SortableContainer(Select)
|
|
301
301
|
: SortableContainer(CreatableSelect);
|
|
302
|
-
|
|
303
302
|
return (
|
|
304
303
|
<FormFieldWrapper {...this.props}>
|
|
305
304
|
<SortableSelect
|
|
306
305
|
useDragHandle
|
|
307
306
|
// react-sortable-hoc props:
|
|
308
307
|
axis="xy"
|
|
309
|
-
onSortEnd={
|
|
308
|
+
onSortEnd={(sortProp) => {
|
|
309
|
+
this.onSortEnd(selectedOption, sortProp);
|
|
310
|
+
}}
|
|
310
311
|
menuShouldScrollIntoView={false}
|
|
311
312
|
distance={4}
|
|
312
313
|
// small fix for https://github.com/clauderic/react-sortable-hoc/pull/352:
|
|
@@ -325,7 +326,9 @@ class ArrayWidget extends Component {
|
|
|
325
326
|
: this.props.choices
|
|
326
327
|
? [
|
|
327
328
|
...choices,
|
|
328
|
-
...(this.props.noValueOption &&
|
|
329
|
+
...(this.props.noValueOption &&
|
|
330
|
+
(this.props.default === undefined ||
|
|
331
|
+
this.props.default === null)
|
|
329
332
|
? [
|
|
330
333
|
{
|
|
331
334
|
label: this.props.intl.formatMessage(
|
package/src/index.js
CHANGED
|
@@ -53,6 +53,7 @@ import reducers from './reducers';
|
|
|
53
53
|
import CookieBanner from 'volto-cookie-banner/CookieBannerContainer';
|
|
54
54
|
import CLMSLoginView from './components/CLMSLoginView/CLMSLogin';
|
|
55
55
|
import AuthomaticLoginPlone from './components/CLMSLoginView/AuthomaticLoginPlone';
|
|
56
|
+
import { withCLMSLoginRoutes } from './loginRoutes';
|
|
56
57
|
//SLATE CONFIGURATION
|
|
57
58
|
import installLinkEditor from '@plone/volto-slate/editor/plugins/AdvancedLink';
|
|
58
59
|
|
|
@@ -271,23 +272,11 @@ const applyConfig = (config) => {
|
|
|
271
272
|
);
|
|
272
273
|
|
|
273
274
|
config.addonRoutes = [
|
|
274
|
-
...
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
{
|
|
280
|
-
path: '/**/login-plone',
|
|
281
|
-
component: AuthomaticLoginPlone,
|
|
282
|
-
},
|
|
283
|
-
{
|
|
284
|
-
path: '/login',
|
|
285
|
-
component: CLMSLoginView,
|
|
286
|
-
},
|
|
287
|
-
{
|
|
288
|
-
path: '/**/login',
|
|
289
|
-
component: CLMSLoginView,
|
|
290
|
-
},
|
|
275
|
+
...withCLMSLoginRoutes(
|
|
276
|
+
config.addonRoutes,
|
|
277
|
+
CLMSLoginView,
|
|
278
|
+
AuthomaticLoginPlone,
|
|
279
|
+
),
|
|
291
280
|
{
|
|
292
281
|
path: '/profile',
|
|
293
282
|
component: ProfileView,
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
const clmsLoginPaths = [
|
|
2
|
+
'/login',
|
|
3
|
+
'/**/login',
|
|
4
|
+
'/login-plone',
|
|
5
|
+
'/**/login-plone',
|
|
6
|
+
];
|
|
7
|
+
|
|
8
|
+
const routeHasCLMSLoginPath = (route) => {
|
|
9
|
+
const paths = Array.isArray(route.path) ? route.path : [route.path];
|
|
10
|
+
return paths.some((path) => clmsLoginPaths.includes(path));
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export const buildLoginRoutes = (Login, LoginPlone) => [
|
|
14
|
+
{
|
|
15
|
+
path: '/login',
|
|
16
|
+
component: Login,
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
path: '/**/login',
|
|
20
|
+
component: Login,
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
path: '/login-plone',
|
|
24
|
+
component: LoginPlone,
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
path: '/**/login-plone',
|
|
28
|
+
component: LoginPlone,
|
|
29
|
+
},
|
|
30
|
+
];
|
|
31
|
+
|
|
32
|
+
export const withCLMSLoginRoutes = (addonRoutes, Login, LoginPlone) => [
|
|
33
|
+
...buildLoginRoutes(Login, LoginPlone),
|
|
34
|
+
...(addonRoutes || []).filter((route) => !routeHasCLMSLoginPath(route)),
|
|
35
|
+
];
|