@postenbring/hedwig-react 0.0.28 → 0.0.29

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.
@@ -3,10 +3,6 @@ import { HTMLAttributes, ReactElement } from 'react';
3
3
 
4
4
  interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
5
5
  children: ReactElement<HTMLLIElement> | ReactElement<HTMLLIElement>[];
6
- /**
7
- * Props passed to the root `nav` html element
8
- */
9
- navProps?: HTMLAttributes<HTMLElement>;
10
6
  /**
11
7
  * Props passed to the `ol` html element
12
8
  */
@@ -18,7 +14,7 @@ interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
18
14
  * **Usage**
19
15
  *
20
16
  * ```tsx
21
- * <Breadcrumbs>
17
+ * <Breadcrumbs data-testid="breadcrumbs">
22
18
  * <li><Link href="../">Previous page</Link></li>
23
19
  * <li>Current page</li>
24
20
  * </Breadcrumbs>
@@ -27,7 +23,7 @@ interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
27
23
  * Outputs this html structure
28
24
  *
29
25
  * ```html
30
- * <nav>
26
+ * <nav data-testid="breadcrumbs">
31
27
  * <ol>
32
28
  * <li><a href="../">Previous page</a></li>
33
29
  * <li>Current page</li>
@@ -35,7 +31,7 @@ interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
35
31
  * </nav>
36
32
  * ```
37
33
  */
38
- declare function Breadcrumbs({ navProps, olProps, children }: BreadcrumbsProps): react_jsx_runtime.JSX.Element;
34
+ declare function Breadcrumbs({ olProps, children, ...rest }: BreadcrumbsProps): react_jsx_runtime.JSX.Element;
39
35
  declare namespace Breadcrumbs {
40
36
  var displayName: string;
41
37
  }
@@ -3,10 +3,6 @@ import { HTMLAttributes, ReactElement } from 'react';
3
3
 
4
4
  interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
5
5
  children: ReactElement<HTMLLIElement> | ReactElement<HTMLLIElement>[];
6
- /**
7
- * Props passed to the root `nav` html element
8
- */
9
- navProps?: HTMLAttributes<HTMLElement>;
10
6
  /**
11
7
  * Props passed to the `ol` html element
12
8
  */
@@ -18,7 +14,7 @@ interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
18
14
  * **Usage**
19
15
  *
20
16
  * ```tsx
21
- * <Breadcrumbs>
17
+ * <Breadcrumbs data-testid="breadcrumbs">
22
18
  * <li><Link href="../">Previous page</Link></li>
23
19
  * <li>Current page</li>
24
20
  * </Breadcrumbs>
@@ -27,7 +23,7 @@ interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
27
23
  * Outputs this html structure
28
24
  *
29
25
  * ```html
30
- * <nav>
26
+ * <nav data-testid="breadcrumbs">
31
27
  * <ol>
32
28
  * <li><a href="../">Previous page</a></li>
33
29
  * <li>Current page</li>
@@ -35,7 +31,7 @@ interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
35
31
  * </nav>
36
32
  * ```
37
33
  */
38
- declare function Breadcrumbs({ navProps, olProps, children }: BreadcrumbsProps): react_jsx_runtime.JSX.Element;
34
+ declare function Breadcrumbs({ olProps, children, ...rest }: BreadcrumbsProps): react_jsx_runtime.JSX.Element;
39
35
  declare namespace Breadcrumbs {
40
36
  var displayName: string;
41
37
  }
@@ -20,6 +20,18 @@ var __spreadValues = (a, b) => {
20
20
  return a;
21
21
  };
22
22
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
23
+ var __objRest = (source, exclude) => {
24
+ var target = {};
25
+ for (var prop in source)
26
+ if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
27
+ target[prop] = source[prop];
28
+ if (source != null && __getOwnPropSymbols)
29
+ for (var prop of __getOwnPropSymbols(source)) {
30
+ if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
31
+ target[prop] = source[prop];
32
+ }
33
+ return target;
34
+ };
23
35
  var __export = (target, all) => {
24
36
  for (var name in all)
25
37
  __defProp(target, name, { get: all[name], enumerable: true });
@@ -42,8 +54,9 @@ __export(breadcrumb_exports, {
42
54
  module.exports = __toCommonJS(breadcrumb_exports);
43
55
  var import_typed_classname = require("@postenbring/hedwig-css/typed-classname/index.mjs");
44
56
  var import_jsx_runtime = require("react/jsx-runtime");
45
- function Breadcrumbs({ navProps, olProps, children }) {
46
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("nav", __spreadProps(__spreadValues({}, navProps), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
57
+ function Breadcrumbs(_a) {
58
+ var _b = _a, { olProps, children } = _b, rest = __objRest(_b, ["olProps", "children"]);
59
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("nav", __spreadProps(__spreadValues({}, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
47
60
  }
48
61
  Breadcrumbs.displayName = "Breadcrumbs";
49
62
  // Annotate the CommonJS export names for ESM import in node:
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Breadcrumbs
3
- } from "../chunk-Q2HYT3Z7.mjs";
3
+ } from "../chunk-5QMPUCNW.mjs";
4
4
  import "../chunk-FUJQIYOF.mjs";
5
5
  export {
6
6
  Breadcrumbs
@@ -20,6 +20,18 @@ var __spreadValues = (a, b) => {
20
20
  return a;
21
21
  };
22
22
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
23
+ var __objRest = (source, exclude) => {
24
+ var target = {};
25
+ for (var prop in source)
26
+ if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
27
+ target[prop] = source[prop];
28
+ if (source != null && __getOwnPropSymbols)
29
+ for (var prop of __getOwnPropSymbols(source)) {
30
+ if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
31
+ target[prop] = source[prop];
32
+ }
33
+ return target;
34
+ };
23
35
  var __export = (target, all) => {
24
36
  for (var name in all)
25
37
  __defProp(target, name, { get: all[name], enumerable: true });
@@ -48,8 +60,9 @@ var import_breadcrumb = require("@postenbring/hedwig-css/dist/breadcrumb.css");
48
60
  // src/breadcrumb/breadcrumb.tsx
49
61
  var import_typed_classname = require("@postenbring/hedwig-css/typed-classname/index.mjs");
50
62
  var import_jsx_runtime = require("react/jsx-runtime");
51
- function Breadcrumbs({ navProps, olProps, children }) {
52
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("nav", __spreadProps(__spreadValues({}, navProps), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
63
+ function Breadcrumbs(_a) {
64
+ var _b = _a, { olProps, children } = _b, rest = __objRest(_b, ["olProps", "children"]);
65
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("nav", __spreadProps(__spreadValues({}, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
53
66
  }
54
67
  Breadcrumbs.displayName = "Breadcrumbs";
55
68
  // Annotate the CommonJS export names for ESM import in node:
@@ -1,7 +1,7 @@
1
1
  import "../chunk-YRAMCYSB.mjs";
2
2
  import {
3
3
  Breadcrumbs
4
- } from "../chunk-Q2HYT3Z7.mjs";
4
+ } from "../chunk-5QMPUCNW.mjs";
5
5
  import "../chunk-FUJQIYOF.mjs";
6
6
  export {
7
7
  Breadcrumbs
@@ -1,4 +1,5 @@
1
1
  import {
2
+ __objRest,
2
3
  __spreadProps,
3
4
  __spreadValues
4
5
  } from "./chunk-FUJQIYOF.mjs";
@@ -6,8 +7,9 @@ import {
6
7
  // src/breadcrumb/breadcrumb.tsx
7
8
  import { clsx } from "@postenbring/hedwig-css/typed-classname/index.mjs";
8
9
  import { jsx } from "react/jsx-runtime";
9
- function Breadcrumbs({ navProps, olProps, children }) {
10
- return /* @__PURE__ */ jsx("nav", __spreadProps(__spreadValues({}, navProps), { children: /* @__PURE__ */ jsx("ol", __spreadProps(__spreadValues({}, olProps), { className: clsx("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
10
+ function Breadcrumbs(_a) {
11
+ var _b = _a, { olProps, children } = _b, rest = __objRest(_b, ["olProps", "children"]);
12
+ return /* @__PURE__ */ jsx("nav", __spreadProps(__spreadValues({}, rest), { children: /* @__PURE__ */ jsx("ol", __spreadProps(__spreadValues({}, olProps), { className: clsx("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
11
13
  }
12
14
  Breadcrumbs.displayName = "Breadcrumbs";
13
15
 
package/dist/index.js CHANGED
@@ -819,8 +819,9 @@ var import_breadcrumb = require("@postenbring/hedwig-css/dist/breadcrumb.css");
819
819
  // src/breadcrumb/breadcrumb.tsx
820
820
  var import_typed_classname14 = require("@postenbring/hedwig-css/typed-classname/index.mjs");
821
821
  var import_jsx_runtime15 = require("react/jsx-runtime");
822
- function Breadcrumbs({ navProps, olProps, children }) {
823
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("nav", __spreadProps(__spreadValues({}, navProps), { children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname14.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
822
+ function Breadcrumbs(_a) {
823
+ var _b = _a, { olProps, children } = _b, rest = __objRest(_b, ["olProps", "children"]);
824
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("nav", __spreadProps(__spreadValues({}, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname14.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
824
825
  }
825
826
  Breadcrumbs.displayName = "Breadcrumbs";
826
827
 
package/dist/index.mjs CHANGED
@@ -58,7 +58,7 @@ import {
58
58
  import "./chunk-YRAMCYSB.mjs";
59
59
  import {
60
60
  Breadcrumbs
61
- } from "./chunk-Q2HYT3Z7.mjs";
61
+ } from "./chunk-5QMPUCNW.mjs";
62
62
  import "./chunk-VX6MSLLO.mjs";
63
63
  import {
64
64
  BaseButton,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@postenbring/hedwig-react",
3
- "version": "0.0.28",
3
+ "version": "0.0.29",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",
@@ -19,7 +19,7 @@
19
19
  "hedwig-tsconfig": "0.0.0"
20
20
  },
21
21
  "dependencies": {
22
- "@postenbring/hedwig-css": "0.0.26"
22
+ "@postenbring/hedwig-css": "0.0.27"
23
23
  },
24
24
  "publishConfig": {
25
25
  "access": "public"