@kitconcept/volto-light-theme 6.0.0-alpha.23 → 6.0.0-alpha.24
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.draft +5 -4
- package/CHANGELOG.md +8 -0
- package/package.json +2 -2
- package/src/components/Footer/slots/CoreFooter.tsx +7 -7
- package/src/components/Footer/slots/FollowUsLogoAndLinks.tsx +2 -2
- package/src/components/StickyMenu/StickyMenu.tsx +36 -0
- package/src/config/settings.ts +1 -1
- package/src/config/slots.ts +8 -1
- package/src/index.ts +3 -1
- package/src/{components/Footer → primitives}/IconLinkList.tsx +1 -1
- package/src/{components/Footer → primitives}/LinkList.tsx +1 -1
- package/src/theme/_footer.scss +1 -1
- package/src/theme/_utils.scss +1 -1
- package/src/theme/_variables.scss +5 -0
- package/src/theme/blocks/_highlight.scss +2 -0
- package/src/theme/blocks/_listing.scss +2 -2
- package/src/theme/blocks/_maps.scss +3 -3
- package/src/theme/main.scss +1 -0
- package/src/theme/sticky-menu.scss +50 -0
- package/src/types.d.ts +7 -0
package/.changelog.draft
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
## 6.0.0-alpha.
|
|
1
|
+
## 6.0.0-alpha.24 (2025-05-06)
|
|
2
2
|
|
|
3
|
-
###
|
|
3
|
+
### Feature
|
|
4
4
|
|
|
5
|
-
-
|
|
6
|
-
-
|
|
5
|
+
- Added `sticky_menu` slot. @sneridagh [#523](https://github.com/kitconcept/volto-light-theme/pull/523)
|
|
6
|
+
- Better naming for the specific kitconcept's behaviors for distributions. @sneridagh [#530](https://github.com/kitconcept/volto-light-theme/pull/530)
|
|
7
|
+
- Use `--image-aspect-ratio` for all images. @danalvrz [#533](https://github.com/kitconcept/volto-light-theme/pull/533)
|
|
7
8
|
|
|
8
9
|
|
package/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,14 @@
|
|
|
8
8
|
|
|
9
9
|
<!-- towncrier release notes start -->
|
|
10
10
|
|
|
11
|
+
## 6.0.0-alpha.24 (2025-05-06)
|
|
12
|
+
|
|
13
|
+
### Feature
|
|
14
|
+
|
|
15
|
+
- Added `sticky_menu` slot. @sneridagh [#523](https://github.com/kitconcept/volto-light-theme/pull/523)
|
|
16
|
+
- Better naming for the specific kitconcept's behaviors for distributions. @sneridagh [#530](https://github.com/kitconcept/volto-light-theme/pull/530)
|
|
17
|
+
- Use `--image-aspect-ratio` for all images. @danalvrz [#533](https://github.com/kitconcept/volto-light-theme/pull/533)
|
|
18
|
+
|
|
11
19
|
## 6.0.0-alpha.23 (2025-04-30)
|
|
12
20
|
|
|
13
21
|
### Bugfix
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kitconcept/volto-light-theme",
|
|
3
|
-
"version": "6.0.0-alpha.
|
|
3
|
+
"version": "6.0.0-alpha.24",
|
|
4
4
|
"description": "Volto Light Theme by kitconcept",
|
|
5
5
|
"main": "src/index.ts",
|
|
6
6
|
"types": "src/index.ts",
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"@types/react": "^18.3.12",
|
|
34
34
|
"@types/react-dom": "^18.3.1",
|
|
35
35
|
"release-it": "^17.7.0",
|
|
36
|
-
"@plone/types": "1.4.
|
|
36
|
+
"@plone/types": "1.4.3"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@dnd-kit/core": "6.0.8",
|
|
@@ -8,30 +8,30 @@ import type { Content } from '@plone/types';
|
|
|
8
8
|
const CoreFooter = ({ content }: { content: Content }) => {
|
|
9
9
|
const footer_address = useLiveData<SiteFooterSettings['footer_address']>(
|
|
10
10
|
content,
|
|
11
|
-
'kitconcept.
|
|
11
|
+
'kitconcept.footer',
|
|
12
12
|
'footer_address',
|
|
13
13
|
);
|
|
14
14
|
|
|
15
15
|
const footer_column_left_header = useLiveData<
|
|
16
16
|
SiteFooterSettings['footer_column_left_header']
|
|
17
|
-
>(content, 'kitconcept.
|
|
17
|
+
>(content, 'kitconcept.footer', 'footer_column_left_header');
|
|
18
18
|
const footer_column_left = useLiveData<
|
|
19
19
|
SiteFooterSettings['footer_column_left']
|
|
20
|
-
>(content, 'kitconcept.
|
|
20
|
+
>(content, 'kitconcept.footer', 'footer_column_left');
|
|
21
21
|
|
|
22
22
|
const footer_column_middle_header = useLiveData<
|
|
23
23
|
SiteFooterSettings['footer_column_middle_header']
|
|
24
|
-
>(content, 'kitconcept.
|
|
24
|
+
>(content, 'kitconcept.footer', 'footer_column_middle_header');
|
|
25
25
|
const footer_column_middle = useLiveData<
|
|
26
26
|
SiteFooterSettings['footer_column_middle']
|
|
27
|
-
>(content, 'kitconcept.
|
|
27
|
+
>(content, 'kitconcept.footer', 'footer_column_middle');
|
|
28
28
|
|
|
29
29
|
const footer_column_right_header = useLiveData<
|
|
30
30
|
SiteFooterSettings['footer_column_right_header']
|
|
31
|
-
>(content, 'kitconcept.
|
|
31
|
+
>(content, 'kitconcept.footer', 'footer_column_right_header');
|
|
32
32
|
const footer_column_right = useLiveData<
|
|
33
33
|
SiteFooterSettings['footer_column_right']
|
|
34
|
-
>(content, 'kitconcept.
|
|
34
|
+
>(content, 'kitconcept.footer', 'footer_column_right');
|
|
35
35
|
|
|
36
36
|
return (
|
|
37
37
|
<Container className="footer">
|
|
@@ -4,7 +4,7 @@ import { flattenToAppURL } from '@plone/volto/helpers/Url/Url';
|
|
|
4
4
|
import ConditionalLink from '@plone/volto/components/manage/ConditionalLink/ConditionalLink';
|
|
5
5
|
import { Container } from '@plone/components';
|
|
6
6
|
import { useLiveData } from '@kitconcept/volto-light-theme/helpers/useLiveData';
|
|
7
|
-
import LinkList from '
|
|
7
|
+
import LinkList from '../../../primitives/LinkList';
|
|
8
8
|
import type {
|
|
9
9
|
PloneGobrSocialMediaSettings,
|
|
10
10
|
SiteFooterSettings,
|
|
@@ -25,7 +25,7 @@ const FollowUsPostFooterLogoAndLinks = ({ content }: { content: Content }) => {
|
|
|
25
25
|
|
|
26
26
|
const footer_logo = useLiveData<SiteFooterSettings['footer_logo']>(
|
|
27
27
|
content,
|
|
28
|
-
'kitconcept.
|
|
28
|
+
'kitconcept.footer',
|
|
29
29
|
'footer_logo',
|
|
30
30
|
);
|
|
31
31
|
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { useLiveData } from '@kitconcept/volto-light-theme/helpers/useLiveData';
|
|
2
|
+
import IconLinkList from '@kitconcept/volto-light-theme/primitives/IconLinkList';
|
|
3
|
+
import type { StickyMenuSettings } from '../../types';
|
|
4
|
+
import type { Content } from '@plone/types';
|
|
5
|
+
|
|
6
|
+
const StickyMenu = ({ content }: { content: Content }) => {
|
|
7
|
+
const menuData = useLiveData<StickyMenuSettings['sticky_menu']>(
|
|
8
|
+
content,
|
|
9
|
+
'kitconcept.sticky_menu',
|
|
10
|
+
'sticky_menu',
|
|
11
|
+
);
|
|
12
|
+
|
|
13
|
+
const sticky_menu_color = useLiveData<
|
|
14
|
+
StickyMenuSettings['sticky_menu_color']
|
|
15
|
+
>(content, 'kitconcept.sticky_menu', 'sticky_menu_color');
|
|
16
|
+
|
|
17
|
+
const sticky_menu_foreground_color = useLiveData<
|
|
18
|
+
StickyMenuSettings['sticky_menu_foreground_color']
|
|
19
|
+
>(content, 'kitconcept.sticky_menu', 'sticky_menu_foreground_color');
|
|
20
|
+
|
|
21
|
+
return (
|
|
22
|
+
<div
|
|
23
|
+
className="sticky-menu"
|
|
24
|
+
style={
|
|
25
|
+
{
|
|
26
|
+
'--sticky-menu-color': sticky_menu_color,
|
|
27
|
+
'--sticky-menu-foreground-color': sticky_menu_foreground_color,
|
|
28
|
+
} as React.CSSProperties
|
|
29
|
+
}
|
|
30
|
+
>
|
|
31
|
+
<IconLinkList iconLinks={menuData} />
|
|
32
|
+
</div>
|
|
33
|
+
);
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export default StickyMenu;
|
package/src/config/settings.ts
CHANGED
|
@@ -21,7 +21,7 @@ type apiExpanderInherit = {
|
|
|
21
21
|
|
|
22
22
|
export default function install(config: ConfigType) {
|
|
23
23
|
const EXPANDERS_INHERIT_BEHAVIORS =
|
|
24
|
-
'voltolighttheme.header,voltolighttheme.theme,voltolighttheme.footer,kitconcept.
|
|
24
|
+
'voltolighttheme.header,voltolighttheme.theme,voltolighttheme.footer,kitconcept.footer,kitconcept.sticky_menu';
|
|
25
25
|
config.settings.enableAutoBlockGroupingByBackgroundColor = true;
|
|
26
26
|
config.settings.navDepth = 3;
|
|
27
27
|
config.settings.slate.useLinkedHeadings = false;
|
package/src/config/slots.ts
CHANGED
|
@@ -4,6 +4,7 @@ import FooterLogos from '../components/Footer/slots/FooterLogos';
|
|
|
4
4
|
import FollowUsLogoAndLinks from '../components/Footer/slots/FollowUsLogoAndLinks';
|
|
5
5
|
import Colophon from '../components/Footer/slots/Colophon';
|
|
6
6
|
import CoreFooter from '../components/Footer/slots/CoreFooter';
|
|
7
|
+
import StickyMenu from '../components/StickyMenu/StickyMenu';
|
|
7
8
|
import type { Content } from '@plone/types';
|
|
8
9
|
|
|
9
10
|
export function hasInheritedBehavior(behavior: string) {
|
|
@@ -18,6 +19,12 @@ export default function install(config: ConfigType) {
|
|
|
18
19
|
component: Theming,
|
|
19
20
|
});
|
|
20
21
|
|
|
22
|
+
config.registerSlotComponent({
|
|
23
|
+
slot: 'aboveHeader',
|
|
24
|
+
name: 'StickyMenu',
|
|
25
|
+
component: StickyMenu,
|
|
26
|
+
});
|
|
27
|
+
|
|
21
28
|
config.registerSlotComponent({
|
|
22
29
|
name: 'footerLogos',
|
|
23
30
|
slot: 'preFooter',
|
|
@@ -28,7 +35,7 @@ export default function install(config: ConfigType) {
|
|
|
28
35
|
name: 'coreFooter',
|
|
29
36
|
slot: 'footer',
|
|
30
37
|
component: CoreFooter,
|
|
31
|
-
predicates: [hasInheritedBehavior('kitconcept.
|
|
38
|
+
predicates: [hasInheritedBehavior('kitconcept.footer')],
|
|
32
39
|
});
|
|
33
40
|
|
|
34
41
|
config.registerSlotComponent({
|
package/src/index.ts
CHANGED
|
@@ -21,6 +21,7 @@ import type {
|
|
|
21
21
|
SiteHeaderSettings,
|
|
22
22
|
SiteThemeSettings,
|
|
23
23
|
SiteFooterSettings,
|
|
24
|
+
StickyMenuSettings,
|
|
24
25
|
PloneGobrSocialMediaSettings,
|
|
25
26
|
} from './types';
|
|
26
27
|
|
|
@@ -55,7 +56,8 @@ declare module '@plone/types' {
|
|
|
55
56
|
'voltolighttheme.header': CustomInheritBehavior<SiteHeaderSettings>;
|
|
56
57
|
'voltolighttheme.theme': CustomInheritBehavior<SiteThemeSettings>;
|
|
57
58
|
'voltolighttheme.footer': CustomInheritBehavior<SiteFooterSettings>;
|
|
58
|
-
'kitconcept.
|
|
59
|
+
'kitconcept.sticky_menu': CustomInheritBehavior<StickyMenuSettings>;
|
|
60
|
+
'kitconcept.footer': CustomInheritBehavior<SiteFooterSettings>;
|
|
59
61
|
'plonegovbr.socialmedia.settings': CustomInheritBehavior<PloneGobrSocialMediaSettings>;
|
|
60
62
|
};
|
|
61
63
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { flattenToAppURL } from '@plone/volto/helpers/Url/Url';
|
|
2
2
|
import ConditionalLink from '@plone/volto/components/manage/ConditionalLink/ConditionalLink';
|
|
3
|
-
import type { iconLink } from '
|
|
3
|
+
import type { iconLink } from '../types';
|
|
4
4
|
|
|
5
5
|
type IconLinkListProps = {
|
|
6
6
|
iconLinks: Array<iconLink>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import isEmpty from 'lodash/isEmpty';
|
|
2
2
|
import { flattenToAppURL } from '@plone/volto/helpers/Url/Url';
|
|
3
3
|
import UniversalLink from '@plone/volto/components/manage/UniversalLink/UniversalLink';
|
|
4
|
-
import type { Link } from '
|
|
4
|
+
import type { Link } from '../types';
|
|
5
5
|
|
|
6
6
|
type LinksProps = { links: Array<Link> };
|
|
7
7
|
|
package/src/theme/_footer.scss
CHANGED
package/src/theme/_utils.scss
CHANGED
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
img {
|
|
83
83
|
width: 220px;
|
|
84
84
|
height: min-content;
|
|
85
|
-
aspect-ratio: $aspect-ratio !important;
|
|
85
|
+
aspect-ratio: var(--image-aspect-ratio, $aspect-ratio) !important;
|
|
86
86
|
@container (max-width: #{$largest-mobile-screen}) {
|
|
87
87
|
width: 100%;
|
|
88
88
|
min-width: 335px;
|
|
@@ -177,7 +177,7 @@
|
|
|
177
177
|
img.item-image {
|
|
178
178
|
width: 100%;
|
|
179
179
|
margin: 0;
|
|
180
|
-
aspect-ratio: $aspect-ratio !important;
|
|
180
|
+
aspect-ratio: var(--image-aspect-ratio, $aspect-ratio) !important;
|
|
181
181
|
}
|
|
182
182
|
|
|
183
183
|
.item {
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
.block.maps {
|
|
2
2
|
iframe {
|
|
3
3
|
height: unset;
|
|
4
|
-
aspect-ratio: $aspect-ratio;
|
|
4
|
+
aspect-ratio: var(--image-aspect-ratio, $aspect-ratio);
|
|
5
5
|
}
|
|
6
6
|
&.align.left {
|
|
7
7
|
iframe {
|
|
8
8
|
height: unset;
|
|
9
9
|
margin-right: 20px !important;
|
|
10
10
|
margin-bottom: 20px !important;
|
|
11
|
-
aspect-ratio: $aspect-ratio;
|
|
11
|
+
aspect-ratio: var(--image-aspect-ratio, $aspect-ratio);
|
|
12
12
|
@container (max-width: #{$largest-mobile-screen}) {
|
|
13
13
|
margin-bottom: $spacing-large !important;
|
|
14
14
|
}
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
height: unset;
|
|
22
22
|
margin-bottom: 20px !important;
|
|
23
23
|
margin-left: 20px !important;
|
|
24
|
-
aspect-ratio: $aspect-ratio;
|
|
24
|
+
aspect-ratio: var(--image-aspect-ratio, $aspect-ratio);
|
|
25
25
|
@container (max-width: #{$largest-mobile-screen}) {
|
|
26
26
|
margin-bottom: $spacing-large !important;
|
|
27
27
|
}
|
package/src/theme/main.scss
CHANGED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
.sticky-menu {
|
|
2
|
+
position: fixed;
|
|
3
|
+
z-index: 1000;
|
|
4
|
+
top: 373px;
|
|
5
|
+
right: 0;
|
|
6
|
+
|
|
7
|
+
ul {
|
|
8
|
+
display: flex;
|
|
9
|
+
width: 115px;
|
|
10
|
+
flex-direction: column;
|
|
11
|
+
padding: 0;
|
|
12
|
+
margin: 0;
|
|
13
|
+
list-style: none;
|
|
14
|
+
|
|
15
|
+
li a {
|
|
16
|
+
display: flex;
|
|
17
|
+
height: 93px;
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
align-items: center;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
margin-bottom: 2px;
|
|
22
|
+
background: var(--sticky-menu-color, #555);
|
|
23
|
+
color: var(--sticky-menu-foreground-color, #fff);
|
|
24
|
+
font-family: Inter;
|
|
25
|
+
font-size: 10px;
|
|
26
|
+
font-style: normal;
|
|
27
|
+
font-weight: 700;
|
|
28
|
+
line-height: 18px; /* 180% */
|
|
29
|
+
text-transform: capitalize;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.image-wrapper {
|
|
33
|
+
height: 65px;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
img {
|
|
37
|
+
width: 100%;
|
|
38
|
+
max-width: 65px;
|
|
39
|
+
height: auto;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
@media only screen and (max-width: $largest-mobile-screen) {
|
|
44
|
+
display: none;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
body.view-editview .sticky-menu {
|
|
49
|
+
display: none;
|
|
50
|
+
}
|
package/src/types.d.ts
CHANGED
|
@@ -75,6 +75,12 @@ export type SiteFooterSettings = {
|
|
|
75
75
|
footer_links: Array<Link>;
|
|
76
76
|
};
|
|
77
77
|
|
|
78
|
+
export type StickyMenuSettings = {
|
|
79
|
+
sticky_menu: Array<iconLink>;
|
|
80
|
+
sticky_menu_color: string;
|
|
81
|
+
sticky_menu_foreground_color: string;
|
|
82
|
+
};
|
|
83
|
+
|
|
78
84
|
export type PloneGobrSocialMediaSettings = {
|
|
79
85
|
social_links: Array<iconLink>;
|
|
80
86
|
};
|
|
@@ -90,6 +96,7 @@ export type CustomInheritBehavior<T> = {
|
|
|
90
96
|
declare module '@plone/types' {
|
|
91
97
|
export interface Content {
|
|
92
98
|
footer_logos: Array<footerLogo>;
|
|
99
|
+
sticky_menu: Array<stickyMenu>;
|
|
93
100
|
footer_links: Array<Link>;
|
|
94
101
|
}
|
|
95
102
|
}
|