@indico-data/design-system 2.45.5 → 2.46.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/lib/index.js CHANGED
@@ -22501,12 +22501,13 @@ const Card = (_a) => {
22501
22501
  return (jsxRuntime.jsxs("div", Object.assign({ className: cardClasses }, rest, { children: [(title || subtitle) && (jsxRuntime.jsxs("div", { className: "card__header", children: [title && jsxRuntime.jsx("h2", { children: title }), subtitle && jsxRuntime.jsx("p", { children: subtitle })] })), jsxRuntime.jsx("div", { className: "card__content", children: children })] })));
22502
22502
  };
22503
22503
 
22504
- function Menu({ children }) {
22505
- return (jsxRuntime.jsx("div", { className: "menu", children: React__namespace.default.Children.map(children, (child) => React__namespace.default.isValidElement(child)
22504
+ function Menu(_a) {
22505
+ var { children, className } = _a, rest = __rest(_a, ["children", "className"]);
22506
+ return (jsxRuntime.jsx("div", Object.assign({ className: classNames('menu', className) }, rest, { children: React__namespace.default.Children.map(children, (child) => React__namespace.default.isValidElement(child)
22506
22507
  ? React__namespace.default.cloneElement(child, {
22507
22508
  className: classNames(child.props.className, 'menu-item'),
22508
22509
  })
22509
- : child) }));
22510
+ : child) })));
22510
22511
  }
22511
22512
 
22512
22513
  const Pill = (_a) => {
@@ -22518,6 +22519,15 @@ const Pill = (_a) => {
22518
22519
  return (jsxRuntime.jsx("div", Object.assign({ className: pillClasses }, rest, { children: children })));
22519
22520
  };
22520
22521
 
22522
+ const Badge = (_a) => {
22523
+ var { className = '', children, size = 'md', string } = _a, rest = __rest(_a, ["className", "children", "size", "string"]);
22524
+ const badgeClasses = classNames('badge', {
22525
+ [`badge--${size}`]: size,
22526
+ }, className);
22527
+ return (jsxRuntime.jsx("div", Object.assign({ className: badgeClasses }, rest, { children: string ? jsxRuntime.jsx("p", { children: string }) : children })));
22528
+ };
22529
+
22530
+ exports.Badge = Badge;
22521
22531
  exports.BarSpinner = BarSpinner;
22522
22532
  exports.Button = Button$1;
22523
22533
  exports.Card = Card;