@aurora-ds/components 1.7.9 → 1.7.11

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/dist/cjs/index.js CHANGED
@@ -5420,6 +5420,12 @@ const Grid = ({ display = 'grid', columns, rows, autoFlow, autoColumns, autoRows
5420
5420
  };
5421
5421
  Grid.displayName = 'Grid';
5422
5422
 
5423
+ const HEADER_STYLES = theme.createStyles((theme) => ({
5424
+ withBorder: () => ({
5425
+ borderBottom: `1px solid ${theme.colors.borderMain}`,
5426
+ }),
5427
+ }), { id: 'header' });
5428
+
5423
5429
  /**
5424
5430
  * Semantic `<header>` enriched with the same token-aware style props as `Box`.
5425
5431
  *
@@ -5428,11 +5434,12 @@ Grid.displayName = 'Grid';
5428
5434
  * `banner` landmark when it is a direct child of `<body>`.
5429
5435
  *
5430
5436
  * @example <Header padding="md" display="flex" alignItems="center" gap="sm">…</Header>
5437
+ * @example <Header withBorder>…</Header>
5431
5438
  */
5432
- const Header = ({ ref, style, className, children, ...props }) => {
5439
+ const Header = ({ ref, style, className, children, withBorder = true, ...props }) => {
5433
5440
  const { styleProps, restProps } = extractBoxStyleProps(props);
5434
5441
  const generatedClassName = BOX_STYLES.root(styleProps);
5435
- return (jsxRuntime.jsx("header", { ref: ref, className: theme.cx(generatedClassName, className), style: style, ...restProps, children: children }));
5442
+ return (jsxRuntime.jsx("header", { ref: ref, className: theme.cx(generatedClassName, withBorder && HEADER_STYLES.withBorder(), className), style: style, ...restProps, children: children }));
5436
5443
  };
5437
5444
  Header.displayName = 'Header';
5438
5445
 
@@ -5926,7 +5933,7 @@ const DrawerItem = ({ startIcon, label, selected = false, endContent, href, onCl
5926
5933
  onClick(e);
5927
5934
  }
5928
5935
  };
5929
- const innerContent = (jsxRuntime.jsxs(Stack, { width: '100%', justifyContent: 'start', children: [jsxRuntime.jsx("span", { className: DRAWER_ITEM_STYLES.iconWrap, children: jsxRuntime.jsx(Icon, { icon: startIcon, size: 'md' }) }), isLabelVisible && (jsxRuntime.jsxs("span", { className: DRAWER_ITEM_STYLES.labelWrapper({ isFadingIn: isLabelFadingIn }), children: [jsxRuntime.jsx(Text, { variant: 'span', fontSize: 'sm', fontWeight: 'medium', className: DRAWER_ITEM_STYLES.label, textAlign: 'start', children: label }), endContent && (jsxRuntime.jsx("span", { className: DRAWER_ITEM_STYLES.endContent, children: endContent }))] }))] }));
5936
+ const innerContent = (jsxRuntime.jsxs(Stack, { width: '100%', justifyContent: 'start', children: [startIcon && (jsxRuntime.jsx("span", { className: DRAWER_ITEM_STYLES.iconWrap, children: jsxRuntime.jsx(Icon, { icon: startIcon, size: 'md' }) })), isLabelVisible && (jsxRuntime.jsxs("span", { className: DRAWER_ITEM_STYLES.labelWrapper({ isFadingIn: isLabelFadingIn }), children: [jsxRuntime.jsx(Text, { variant: 'span', fontSize: 'sm', fontWeight: 'medium', className: DRAWER_ITEM_STYLES.label, textAlign: 'start', children: label }), endContent && (jsxRuntime.jsx("span", { className: DRAWER_ITEM_STYLES.endContent, children: endContent }))] }))] }));
5930
5937
  const item = href ? (jsxRuntime.jsx("a", { href: href, className: rootClassName, "aria-disabled": disabled || undefined, "aria-current": computedAriaCurrent, "aria-label": computedAriaLabel, "aria-labelledby": ariaLabelledBy, "aria-describedby": ariaDescribedBy, "aria-controls": ariaControls, "aria-expanded": ariaExpanded, "aria-haspopup": ariaHasPopup, tabIndex: disabled ? -1 : undefined, onClick: handleClick, children: innerContent })) : (jsxRuntime.jsx("button", { type: 'button', className: rootClassName, disabled: disabled, "aria-current": computedAriaCurrent, "aria-label": computedAriaLabel, "aria-labelledby": ariaLabelledBy, "aria-describedby": ariaDescribedBy, "aria-controls": ariaControls, "aria-expanded": ariaExpanded, "aria-haspopup": ariaHasPopup, onClick: handleClick, children: innerContent }));
5931
5938
  return (jsxRuntime.jsx(Tooltip, { label: label, placement: 'right', inline: true, withArrow: true, disabled: isExpanded || disabled, children: item }));
5932
5939
  };