@eeacms/volto-n2k 1.0.24 → 1.0.25
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,16 +4,18 @@ 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.0.25](https://github.com/eea/volto-n2k/compare/1.0.24...1.0.25) - 26 April 2023
|
|
8
|
+
|
|
9
|
+
#### :rocket: New Features
|
|
10
|
+
|
|
11
|
+
- feat(Group/EditBlockWrapper.jsx): add support for custom styles in group block editing mode [Miu Razvan - [`97daa39`](https://github.com/eea/volto-n2k/commit/97daa39e8b3bb7a8c04b357706bb79126c2faecf)]
|
|
12
|
+
|
|
7
13
|
### [1.0.24](https://github.com/eea/volto-n2k/compare/1.0.23...1.0.24) - 26 April 2023
|
|
8
14
|
|
|
9
15
|
#### :house: Internal changes
|
|
10
16
|
|
|
11
17
|
- style: fix margin-bottom position in habitat-banner-details and species-banner-details [Miu Razvan - [`4e78d69`](https://github.com/eea/volto-n2k/commit/4e78d6927829f18a91f6b409ee670b01d538dba6)]
|
|
12
18
|
|
|
13
|
-
#### :hammer_and_wrench: Others
|
|
14
|
-
|
|
15
|
-
- update [Miu Razvan - [`4347ffc`](https://github.com/eea/volto-n2k/commit/4347ffc93743dbc9d5514fe1f7d6e39b73abd0c8)]
|
|
16
|
-
- update [Miu Razvan - [`4e8317f`](https://github.com/eea/volto-n2k/commit/4e8317ffbe459d5bc15092fa9f43255707a77e37)]
|
|
17
19
|
### [1.0.23](https://github.com/eea/volto-n2k/compare/1.0.22...1.0.23) - 12 April 2023
|
|
18
20
|
|
|
19
21
|
#### :house: Internal changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Icon, BlockChooser } from '@plone/volto/components';
|
|
3
|
-
import {
|
|
3
|
+
import {
|
|
4
|
+
blockHasValue,
|
|
5
|
+
buildStyleClassNamesFromData,
|
|
6
|
+
} from '@plone/volto/helpers';
|
|
4
7
|
import config from '@plone/volto/registry';
|
|
5
8
|
import { Button } from 'semantic-ui-react';
|
|
6
9
|
import includes from 'lodash/includes';
|
|
@@ -86,6 +89,8 @@ class EditBlockWrapper extends React.Component {
|
|
|
86
89
|
? data.required
|
|
87
90
|
: includes(config.blocks.requiredBlocks, type);
|
|
88
91
|
|
|
92
|
+
const styles = buildStyleClassNamesFromData(data.styles);
|
|
93
|
+
|
|
89
94
|
// Get editing instructions from block settings or props
|
|
90
95
|
let instructions = data?.instructions?.data || data?.instructions;
|
|
91
96
|
if (!instructions || instructions === '<p><br/></p>') {
|
|
@@ -97,7 +102,9 @@ class EditBlockWrapper extends React.Component {
|
|
|
97
102
|
<div
|
|
98
103
|
ref={draginfo?.innerRef}
|
|
99
104
|
{...(selected ? draginfo?.draggableProps : null)}
|
|
100
|
-
className={`block-editor-${data['@type']}
|
|
105
|
+
className={cx(`block-editor-${data['@type']}`, styles, {
|
|
106
|
+
[data.align]: data.align,
|
|
107
|
+
})}
|
|
101
108
|
>
|
|
102
109
|
{(!selected || !visible || disabled) && (
|
|
103
110
|
<div
|