@reykjavik/hanna-react 0.10.150 → 0.10.151
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 +9 -0
- package/Heading.js +1 -6
- package/Layout.js +1 -1
- package/esm/Heading.js +1 -6
- package/esm/Layout.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,15 @@
|
|
|
4
4
|
|
|
5
5
|
- ... <!-- Add new lines here. -->
|
|
6
6
|
|
|
7
|
+
## 0.10.151
|
|
8
|
+
|
|
9
|
+
_2025-05-22_
|
|
10
|
+
|
|
11
|
+
- `Heading`:
|
|
12
|
+
- fix: Apply `wrapperProps.className` standalone, not as a modifier
|
|
13
|
+
- `Layout`:
|
|
14
|
+
- fix: Suppress rendering of empty `.Layout__footer`
|
|
15
|
+
|
|
7
16
|
## 0.10.150
|
|
8
17
|
|
|
9
18
|
_2025-05-08_
|
package/Heading.js
CHANGED
|
@@ -14,12 +14,7 @@ const Heading = (props) => {
|
|
|
14
14
|
const { size = 'normal', align, wide, children, wrapperProps } = props;
|
|
15
15
|
const Tag = props.Tag || (props.forceH1 ? 'h1' : 'h2');
|
|
16
16
|
const suppressWarning = process.env.NODE_ENV !== 'production' && Tag === 'h1' ? true : undefined;
|
|
17
|
-
return (react_1.default.createElement(Tag, Object.assign({}, wrapperProps, { "data-dev-forcedh1": suppressWarning, className: (0, hanna_utils_1.modifiedClass)('Heading', [
|
|
18
|
-
sizes[size],
|
|
19
|
-
align === 'right' && `align--${align}`,
|
|
20
|
-
!align && wide && 'wide',
|
|
21
|
-
(wrapperProps || {}).className,
|
|
22
|
-
]) }), children));
|
|
17
|
+
return (react_1.default.createElement(Tag, Object.assign({}, wrapperProps, { "data-dev-forcedh1": suppressWarning, className: (0, hanna_utils_1.modifiedClass)('Heading', [sizes[size], align === 'right' && `align--${align}`, !align && wide && 'wide'], (wrapperProps || {}).className) }), children));
|
|
23
18
|
};
|
|
24
19
|
exports.Heading = Heading;
|
|
25
20
|
exports.default = exports.Heading;
|
package/Layout.js
CHANGED
|
@@ -27,7 +27,7 @@ const Layout = (props) => {
|
|
|
27
27
|
navChildren && (react_1.default.createElement("a", { className: "Layout__header__navlink", href: "#pagenav", onClick: (e) => (0, a11yHelpers_js_1.handleAnchorLinkClick)(e, true), "aria-label": txt.skipLinkLabel }, txt.skipLinkLabel))),
|
|
28
28
|
react_1.default.createElement("div", { className: "Layout__main", role: "main" }, mainChildren || children),
|
|
29
29
|
navChildren && (react_1.default.createElement("div", { className: "Layout__nav", id: "pagenav", tabIndex: -1, role: "navigation" }, navChildren)),
|
|
30
|
-
react_1.default.createElement("div", { className: "Layout__footer", role: "complementary" }, footerChildren))));
|
|
30
|
+
footerChildren && (react_1.default.createElement("div", { className: "Layout__footer", role: "complementary" }, footerChildren)))));
|
|
31
31
|
};
|
|
32
32
|
exports.Layout = Layout;
|
|
33
33
|
exports.default = exports.Layout;
|
package/esm/Heading.js
CHANGED
|
@@ -10,11 +10,6 @@ export const Heading = (props) => {
|
|
|
10
10
|
const { size = 'normal', align, wide, children, wrapperProps } = props;
|
|
11
11
|
const Tag = props.Tag || (props.forceH1 ? 'h1' : 'h2');
|
|
12
12
|
const suppressWarning = process.env.NODE_ENV !== 'production' && Tag === 'h1' ? true : undefined;
|
|
13
|
-
return (React.createElement(Tag, Object.assign({}, wrapperProps, { "data-dev-forcedh1": suppressWarning, className: modifiedClass('Heading', [
|
|
14
|
-
sizes[size],
|
|
15
|
-
align === 'right' && `align--${align}`,
|
|
16
|
-
!align && wide && 'wide',
|
|
17
|
-
(wrapperProps || {}).className,
|
|
18
|
-
]) }), children));
|
|
13
|
+
return (React.createElement(Tag, Object.assign({}, wrapperProps, { "data-dev-forcedh1": suppressWarning, className: modifiedClass('Heading', [sizes[size], align === 'right' && `align--${align}`, !align && wide && 'wide'], (wrapperProps || {}).className) }), children));
|
|
19
14
|
};
|
|
20
15
|
export default Heading;
|
package/esm/Layout.js
CHANGED
|
@@ -23,6 +23,6 @@ export const Layout = (props) => {
|
|
|
23
23
|
navChildren && (React.createElement("a", { className: "Layout__header__navlink", href: "#pagenav", onClick: (e) => handleAnchorLinkClick(e, true), "aria-label": txt.skipLinkLabel }, txt.skipLinkLabel))),
|
|
24
24
|
React.createElement("div", { className: "Layout__main", role: "main" }, mainChildren || children),
|
|
25
25
|
navChildren && (React.createElement("div", { className: "Layout__nav", id: "pagenav", tabIndex: -1, role: "navigation" }, navChildren)),
|
|
26
|
-
React.createElement("div", { className: "Layout__footer", role: "complementary" }, footerChildren))));
|
|
26
|
+
footerChildren && (React.createElement("div", { className: "Layout__footer", role: "complementary" }, footerChildren)))));
|
|
27
27
|
};
|
|
28
28
|
export default Layout;
|