@astral/ui 4.88.0 → 4.88.1

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.
@@ -1,4 +1,5 @@
1
1
  import { styled } from '../../styled';
2
+ import { tabsClassnames } from '../../Tabs';
2
3
  export const BreadcrumbsWrapper = styled.div `
3
4
  grid-column: 2;
4
5
  grid-row: 1;
@@ -13,10 +14,14 @@ export const TabsWrapper = styled.div `
13
14
  grid-column: 1 / -1;
14
15
  grid-row: 4;
15
16
 
16
- padding-top: ${({ theme }) => theme.spacing(3)};
17
+ padding-top: ${({ theme }) => theme.spacing(4)};
17
18
 
18
19
  ${({ theme }) => theme.breakpoints.down('sm')} {
19
- padding: ${({ theme }) => theme.spacing(0, 3, 3, 3)};
20
+ padding: ${({ theme }) => theme.spacing(0, 0, 4, 0)};
21
+
22
+ .${tabsClassnames.root} {
23
+ margin: ${({ theme }) => theme.spacing(0, 4)};
24
+ }
20
25
  }
21
26
  `;
22
27
  export const PageSubheader = styled.div `
@@ -1,4 +1,4 @@
1
1
  import type { TabsProps as MuiTabsProps } from '@mui/material/Tabs';
2
2
  import { type WithoutEmotionSpecific } from '../types/WithoutEmotionSpecific';
3
3
  export type TabsProps = WithoutEmotionSpecific<MuiTabsProps>;
4
- export declare const Tabs: ({ ...tabsProps }: TabsProps) => import("react/jsx-runtime").JSX.Element;
4
+ export declare const Tabs: ({ className, ...tabsProps }: TabsProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,7 +1,9 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { useScrollToActiveElement } from '../useScrollToActiveElement';
3
+ import { classNames } from '../utils/classNames';
4
+ import { tabsClassnames } from './constants';
3
5
  import { Container, Divider, StyledTabs, Wrapper } from './styles';
4
- export const Tabs = ({ ...tabsProps }) => {
6
+ export const Tabs = ({ className, ...tabsProps }) => {
5
7
  const { containerRef } = useScrollToActiveElement();
6
- return (_jsx(Container, { children: _jsxs(Wrapper, { children: [_jsx(StyledTabs, { ...tabsProps, ref: containerRef }), _jsx(Divider, {})] }) }));
8
+ return (_jsx(Container, { children: _jsxs(Wrapper, { children: [_jsx(StyledTabs, { ...tabsProps, ref: containerRef, className: classNames(className, tabsClassnames.root) }), _jsx(Divider, {})] }) }));
7
9
  };
@@ -0,0 +1,3 @@
1
+ export declare const tabsClassnames: {
2
+ root: string;
3
+ };
@@ -0,0 +1,4 @@
1
+ import { createUIKitClassname } from '../utils/createUIKitClassname';
2
+ export const tabsClassnames = {
3
+ root: createUIKitClassname('tabs-root'),
4
+ };
@@ -1,2 +1,3 @@
1
- export * from './Tabs';
1
+ export { tabsClassnames } from './constants';
2
2
  export * from './Tab';
3
+ export * from './Tabs';
@@ -1,2 +1,3 @@
1
- export * from './Tabs';
1
+ export { tabsClassnames } from './constants';
2
2
  export * from './Tab';
3
+ export * from './Tabs';
@@ -1,2 +1,3 @@
1
+ export { tabsClassnames } from './constants';
1
2
  export * from './Tab';
2
3
  export * from './Tabs';
@@ -1,2 +1,3 @@
1
+ export { tabsClassnames } from './constants';
1
2
  export * from './Tab';
2
3
  export * from './Tabs';
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.DesktopTitleWrapper = exports.PageSubheader = exports.TabsWrapper = exports.BreadcrumbsWrapper = void 0;
4
4
  const styled_1 = require("../../styled");
5
+ const Tabs_1 = require("../../Tabs");
5
6
  exports.BreadcrumbsWrapper = styled_1.styled.div `
6
7
  grid-column: 2;
7
8
  grid-row: 1;
@@ -16,10 +17,14 @@ exports.TabsWrapper = styled_1.styled.div `
16
17
  grid-column: 1 / -1;
17
18
  grid-row: 4;
18
19
 
19
- padding-top: ${({ theme }) => theme.spacing(3)};
20
+ padding-top: ${({ theme }) => theme.spacing(4)};
20
21
 
21
22
  ${({ theme }) => theme.breakpoints.down('sm')} {
22
- padding: ${({ theme }) => theme.spacing(0, 3, 3, 3)};
23
+ padding: ${({ theme }) => theme.spacing(0, 0, 4, 0)};
24
+
25
+ .${Tabs_1.tabsClassnames.root} {
26
+ margin: ${({ theme }) => theme.spacing(0, 4)};
27
+ }
23
28
  }
24
29
  `;
25
30
  exports.PageSubheader = styled_1.styled.div `
@@ -1,4 +1,4 @@
1
1
  import type { TabsProps as MuiTabsProps } from '@mui/material/Tabs';
2
2
  import { type WithoutEmotionSpecific } from '../types/WithoutEmotionSpecific';
3
3
  export type TabsProps = WithoutEmotionSpecific<MuiTabsProps>;
4
- export declare const Tabs: ({ ...tabsProps }: TabsProps) => import("react/jsx-runtime").JSX.Element;
4
+ export declare const Tabs: ({ className, ...tabsProps }: TabsProps) => import("react/jsx-runtime").JSX.Element;
@@ -3,9 +3,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Tabs = void 0;
4
4
  const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const useScrollToActiveElement_1 = require("../useScrollToActiveElement");
6
+ const classNames_1 = require("../utils/classNames");
7
+ const constants_1 = require("./constants");
6
8
  const styles_1 = require("./styles");
7
- const Tabs = ({ ...tabsProps }) => {
9
+ const Tabs = ({ className, ...tabsProps }) => {
8
10
  const { containerRef } = (0, useScrollToActiveElement_1.useScrollToActiveElement)();
9
- return ((0, jsx_runtime_1.jsx)(styles_1.Container, { children: (0, jsx_runtime_1.jsxs)(styles_1.Wrapper, { children: [(0, jsx_runtime_1.jsx)(styles_1.StyledTabs, { ...tabsProps, ref: containerRef }), (0, jsx_runtime_1.jsx)(styles_1.Divider, {})] }) }));
11
+ return ((0, jsx_runtime_1.jsx)(styles_1.Container, { children: (0, jsx_runtime_1.jsxs)(styles_1.Wrapper, { children: [(0, jsx_runtime_1.jsx)(styles_1.StyledTabs, { ...tabsProps, ref: containerRef, className: (0, classNames_1.classNames)(className, constants_1.tabsClassnames.root) }), (0, jsx_runtime_1.jsx)(styles_1.Divider, {})] }) }));
10
12
  };
11
13
  exports.Tabs = Tabs;
@@ -0,0 +1,3 @@
1
+ export declare const tabsClassnames: {
2
+ root: string;
3
+ };
@@ -0,0 +1,7 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.tabsClassnames = void 0;
4
+ const createUIKitClassname_1 = require("../utils/createUIKitClassname");
5
+ exports.tabsClassnames = {
6
+ root: (0, createUIKitClassname_1.createUIKitClassname)('tabs-root'),
7
+ };
@@ -1,2 +1,3 @@
1
- export * from './Tabs';
1
+ export { tabsClassnames } from './constants';
2
2
  export * from './Tab';
3
+ export * from './Tabs';
@@ -14,5 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./Tabs"), exports);
17
+ exports.tabsClassnames = void 0;
18
+ var constants_1 = require("./constants");
19
+ Object.defineProperty(exports, "tabsClassnames", { enumerable: true, get: function () { return constants_1.tabsClassnames; } });
18
20
  __exportStar(require("./Tab"), exports);
21
+ __exportStar(require("./Tabs"), exports);
@@ -1,2 +1,3 @@
1
+ export { tabsClassnames } from './constants';
1
2
  export * from './Tab';
2
3
  export * from './Tabs';
@@ -14,5 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ exports.tabsClassnames = void 0;
18
+ var constants_1 = require("./constants");
19
+ Object.defineProperty(exports, "tabsClassnames", { enumerable: true, get: function () { return constants_1.tabsClassnames; } });
17
20
  __exportStar(require("./Tab"), exports);
18
21
  __exportStar(require("./Tabs"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@astral/ui",
3
- "version": "4.88.0",
3
+ "version": "4.88.1",
4
4
  "browser": "./index.js",
5
5
  "main": "./node/index.js",
6
6
  "dependencies": {