@kitconcept/volto-light-theme 1.0.0 → 2.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/.github/workflows/acceptance.yml +1 -1
- package/.github/workflows/changelog.yml +1 -1
- package/.github/workflows/code.yml +1 -1
- package/.github/workflows/deploy.yml +1 -1
- package/.github/workflows/unit.yml +1 -1
- package/CHANGELOG.md +38 -0
- package/Makefile +2 -2
- package/README.md +13 -1
- package/acceptance/cypress/tests/basic.cy.js +1 -1
- package/acceptance/cypress/tests/nav.cy.js +60 -0
- package/locales/de/LC_MESSAGES/volto.po +44 -2
- package/locales/en/LC_MESSAGES/volto.po +49 -2
- package/locales/volto.pot +50 -3
- package/package.json +3 -3
- package/src/components/Blocks/schema.js +5 -0
- package/src/components/Header/Header.jsx +3 -1
- package/src/components/MobileNavigation/MobileNavigation.jsx +300 -0
- package/src/components/Navigation/Navigation.jsx +190 -168
- package/src/index.js +41 -37
- package/src/theme/_bgcolor-blocks-layout.scss +5 -0
- package/src/theme/_header.scss +593 -7
- package/src/theme/blocks/_button.scss +6 -0
- package/src/theme/blocks/_maps.scss +4 -0
package/src/index.js
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import { defineMessages } from 'react-intl';
|
|
2
2
|
|
|
3
3
|
import { composeSchema, getPreviousNextBlock } from '@plone/volto/helpers';
|
|
4
|
-
import {
|
|
4
|
+
import {
|
|
5
|
+
defaultStylingSchema,
|
|
6
|
+
removeStylingSchema,
|
|
7
|
+
} from './components/Blocks/schema';
|
|
5
8
|
import { teaserSchemaEnhancer } from './components/Blocks/Teaser/schema';
|
|
6
9
|
import { videoBlockSchemaEnhancer } from './components/Blocks/Video/schema';
|
|
7
10
|
import { gridTeaserDisableStylingSchema } from '@plone/volto/components/manage/Blocks/Teaser/schema';
|
|
@@ -48,6 +51,7 @@ defineMessages({
|
|
|
48
51
|
const applyConfig = (config) => {
|
|
49
52
|
config.settings.enableAutoBlockGroupingByBackgroundColor = true;
|
|
50
53
|
config.settings.navDepth = 3;
|
|
54
|
+
config.settings.enableFatMenu = true;
|
|
51
55
|
config.settings.slate.useLinkedHeadings = false;
|
|
52
56
|
|
|
53
57
|
// No required blocks (eg. Title)
|
|
@@ -184,43 +188,43 @@ const applyConfig = (config) => {
|
|
|
184
188
|
colors: BG_COLORS,
|
|
185
189
|
schemaEnhancer: defaultStylingSchema,
|
|
186
190
|
icon: gridSVG,
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
},
|
|
203
|
-
},
|
|
204
|
-
image: {
|
|
205
|
-
...config.blocks.blocksConfig.image,
|
|
206
|
-
schemaEnhancer: composeSchema(
|
|
207
|
-
imageBlockSchemaEnhancer,
|
|
208
|
-
gridImageDisableSizeAndPositionHandlersSchema,
|
|
209
|
-
),
|
|
210
|
-
},
|
|
211
|
-
teaser: {
|
|
212
|
-
...config.blocks.blocksConfig.teaser,
|
|
213
|
-
schemaEnhancer: composeSchema(
|
|
214
|
-
gridTeaserDisableStylingSchema,
|
|
215
|
-
teaserSchemaEnhancer,
|
|
216
|
-
),
|
|
217
|
-
},
|
|
218
|
-
listing: {
|
|
219
|
-
...config.blocks.blocksConfig.listing,
|
|
220
|
-
allowed_headline_tags: [['h2', 'h2']],
|
|
221
|
-
variations: config.blocks.blocksConfig.listing.variations,
|
|
191
|
+
};
|
|
192
|
+
|
|
193
|
+
config.blocks.blocksConfig.gridBlock.blocksConfig = {
|
|
194
|
+
...config.blocks.blocksConfig,
|
|
195
|
+
slate: {
|
|
196
|
+
...config.blocks.blocksConfig.slate,
|
|
197
|
+
// Slate in grids must have an extra wrapper with the `slate` className
|
|
198
|
+
view: (props) => {
|
|
199
|
+
const EnhancedSlateViewComponent =
|
|
200
|
+
config.blocks.blocksConfig.slate.view;
|
|
201
|
+
return (
|
|
202
|
+
<div className="slate">
|
|
203
|
+
<EnhancedSlateViewComponent {...props} />
|
|
204
|
+
</div>
|
|
205
|
+
);
|
|
222
206
|
},
|
|
223
207
|
},
|
|
208
|
+
image: {
|
|
209
|
+
...config.blocks.blocksConfig.image,
|
|
210
|
+
schemaEnhancer: composeSchema(
|
|
211
|
+
imageBlockSchemaEnhancer,
|
|
212
|
+
gridImageDisableSizeAndPositionHandlersSchema,
|
|
213
|
+
),
|
|
214
|
+
},
|
|
215
|
+
teaser: {
|
|
216
|
+
...config.blocks.blocksConfig.teaser,
|
|
217
|
+
schemaEnhancer: composeSchema(
|
|
218
|
+
gridTeaserDisableStylingSchema,
|
|
219
|
+
teaserSchemaEnhancer,
|
|
220
|
+
),
|
|
221
|
+
},
|
|
222
|
+
listing: {
|
|
223
|
+
...config.blocks.blocksConfig.listing,
|
|
224
|
+
allowed_headline_tags: [['h2', 'h2']],
|
|
225
|
+
schemaEnhancer: removeStylingSchema,
|
|
226
|
+
variations: [],
|
|
227
|
+
},
|
|
224
228
|
};
|
|
225
229
|
|
|
226
230
|
config.blocks.blocksConfig.introduction = {
|
|
@@ -288,7 +292,7 @@ const applyConfig = (config) => {
|
|
|
288
292
|
};
|
|
289
293
|
|
|
290
294
|
// Check if the separator is present before enhancing it
|
|
291
|
-
if (config.blocks.blocksConfig
|
|
295
|
+
if (config.blocks.blocksConfig?.separator?.id) {
|
|
292
296
|
config.blocks.blocksConfig.separator = {
|
|
293
297
|
...config.blocks.blocksConfig.separator,
|
|
294
298
|
schemaEnhancer: composeSchema(
|