@cloud-ru/uikit-product-site-layout 0.3.0 → 0.4.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/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # 0.4.0 (2025-12-04)
7
+
8
+
9
+ ### Features
10
+
11
+ * **SITE-10318:** edit layout styles ([d4db088](https://gitverse.ru/cloud-ru-tech/uikit-product/commits/d4db088946220586887d3ea7fd2bfe6cf7fc6bd0))
12
+
13
+
14
+
15
+
16
+
6
17
  # 0.3.0 (2025-12-03)
7
18
 
8
19
 
@@ -1,7 +1,7 @@
1
1
  import { ReactNode } from 'react';
2
- import { WithSupportProps } from '@cloud-ru/uikit-product-utils';
3
- export type MainProps = WithSupportProps<{
2
+ import { WithLayoutType, WithSupportProps } from '@cloud-ru/uikit-product-utils';
3
+ export type MainProps = WithSupportProps<WithLayoutType<{
4
4
  children: ReactNode;
5
5
  className?: string;
6
- }>;
7
- export declare function Main({ children, className, ...rest }: MainProps): import("react/jsx-runtime").JSX.Element;
6
+ }>>;
7
+ export declare function Main({ children, className, layoutType, ...rest }: MainProps): import("react/jsx-runtime").JSX.Element;
@@ -20,6 +20,6 @@ const classnames_1 = __importDefault(require("classnames"));
20
20
  const uikit_product_utils_1 = require("@cloud-ru/uikit-product-utils");
21
21
  const styles_module_scss_1 = __importDefault(require('./styles.module.css'));
22
22
  function Main(_a) {
23
- var { children, className } = _a, rest = __rest(_a, ["children", "className"]);
24
- return ((0, jsx_runtime_1.jsx)("main", Object.assign({ className: (0, classnames_1.default)(styles_module_scss_1.default.main, className) }, (0, uikit_product_utils_1.extractSupportProps)(rest), { children: children })));
23
+ var { children, className, layoutType } = _a, rest = __rest(_a, ["children", "className", "layoutType"]);
24
+ return ((0, jsx_runtime_1.jsx)("main", Object.assign({ className: (0, classnames_1.default)(styles_module_scss_1.default.main, className) }, (0, uikit_product_utils_1.extractSupportProps)(rest), { children: (0, jsx_runtime_1.jsx)("div", { className: styles_module_scss_1.default.mainContent, "data-layout-type": layoutType, children: children }) })));
25
25
  }
@@ -2,4 +2,24 @@
2
2
  display:flex;
3
3
  flex:1;
4
4
  flex-direction:inherit;
5
+ background:var(--sys-neutral-background, #eeeff3);
6
+ }
7
+
8
+ .mainContent{
9
+ margin:0 auto;
10
+ width:100%;
11
+ max-width:1440px;
12
+ min-width:0;
13
+ box-sizing:border-box;
14
+ }
15
+ .mainContent[data-layout-type=desktop], .mainContent[data-layout-type=desktopSmall]{
16
+ padding:0 var(--dimension-2m, 16px);
17
+ }
18
+ .mainContent[data-layout-type=tablet]{
19
+ max-width:unset;
20
+ padding:0 var(--dimension-2m, 16px);
21
+ }
22
+ .mainContent[data-layout-type=mobile]{
23
+ max-width:unset;
24
+ padding:0;
5
25
  }
@@ -3,24 +3,19 @@
3
3
  justify-content:center;
4
4
  width:100%;
5
5
  min-width:0;
6
- background:var(--sys-neutral-background, #eeeff3);
7
6
  }
8
7
 
9
8
  .contentWrapper{
10
9
  width:100%;
11
- max-width:1440px;
12
- padding:0;
10
+ max-width:1216px;
11
+ padding:0 var(--dimension-4m, 32px);
13
12
  min-width:0;
14
- box-sizing:border-box;
15
- }
16
- .contentWrapper[data-layout-type=desktop], .contentWrapper[data-layout-type=desktopSmall]{
17
- padding:0 var(--dimension-2m, 16px);
18
13
  }
19
14
  .contentWrapper[data-layout-type=tablet]{
20
15
  max-width:unset;
21
- padding:0 var(--dimension-2m, 16px);
16
+ padding:0 var(--dimension-4m, 32px);
22
17
  }
23
18
  .contentWrapper[data-layout-type=mobile]{
24
19
  max-width:unset;
25
- padding:0;
20
+ padding:0 var(--dimension-2m, 16px);
26
21
  }
@@ -1,7 +1,7 @@
1
1
  import { ReactNode } from 'react';
2
- import { WithSupportProps } from '@cloud-ru/uikit-product-utils';
3
- export type MainProps = WithSupportProps<{
2
+ import { WithLayoutType, WithSupportProps } from '@cloud-ru/uikit-product-utils';
3
+ export type MainProps = WithSupportProps<WithLayoutType<{
4
4
  children: ReactNode;
5
5
  className?: string;
6
- }>;
7
- export declare function Main({ children, className, ...rest }: MainProps): import("react/jsx-runtime").JSX.Element;
6
+ }>>;
7
+ export declare function Main({ children, className, layoutType, ...rest }: MainProps): import("react/jsx-runtime").JSX.Element;
@@ -14,6 +14,6 @@ import cn from 'classnames';
14
14
  import { extractSupportProps } from '@cloud-ru/uikit-product-utils';
15
15
  import styles from './styles.module.css';
16
16
  export function Main(_a) {
17
- var { children, className } = _a, rest = __rest(_a, ["children", "className"]);
18
- return (_jsx("main", Object.assign({ className: cn(styles.main, className) }, extractSupportProps(rest), { children: children })));
17
+ var { children, className, layoutType } = _a, rest = __rest(_a, ["children", "className", "layoutType"]);
18
+ return (_jsx("main", Object.assign({ className: cn(styles.main, className) }, extractSupportProps(rest), { children: _jsx("div", { className: styles.mainContent, "data-layout-type": layoutType, children: children }) })));
19
19
  }
@@ -2,4 +2,24 @@
2
2
  display:flex;
3
3
  flex:1;
4
4
  flex-direction:inherit;
5
+ background:var(--sys-neutral-background, #eeeff3);
6
+ }
7
+
8
+ .mainContent{
9
+ margin:0 auto;
10
+ width:100%;
11
+ max-width:1440px;
12
+ min-width:0;
13
+ box-sizing:border-box;
14
+ }
15
+ .mainContent[data-layout-type=desktop], .mainContent[data-layout-type=desktopSmall]{
16
+ padding:0 var(--dimension-2m, 16px);
17
+ }
18
+ .mainContent[data-layout-type=tablet]{
19
+ max-width:unset;
20
+ padding:0 var(--dimension-2m, 16px);
21
+ }
22
+ .mainContent[data-layout-type=mobile]{
23
+ max-width:unset;
24
+ padding:0;
5
25
  }
@@ -3,24 +3,19 @@
3
3
  justify-content:center;
4
4
  width:100%;
5
5
  min-width:0;
6
- background:var(--sys-neutral-background, #eeeff3);
7
6
  }
8
7
 
9
8
  .contentWrapper{
10
9
  width:100%;
11
- max-width:1440px;
12
- padding:0;
10
+ max-width:1216px;
11
+ padding:0 var(--dimension-4m, 32px);
13
12
  min-width:0;
14
- box-sizing:border-box;
15
- }
16
- .contentWrapper[data-layout-type=desktop], .contentWrapper[data-layout-type=desktopSmall]{
17
- padding:0 var(--dimension-2m, 16px);
18
13
  }
19
14
  .contentWrapper[data-layout-type=tablet]{
20
15
  max-width:unset;
21
- padding:0 var(--dimension-2m, 16px);
16
+ padding:0 var(--dimension-4m, 32px);
22
17
  }
23
18
  .contentWrapper[data-layout-type=mobile]{
24
19
  max-width:unset;
25
- padding:0;
20
+ padding:0 var(--dimension-2m, 16px);
26
21
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@cloud-ru/uikit-product-site-layout",
3
3
  "title": "Site Layout",
4
- "version": "0.3.0",
4
+ "version": "0.4.0",
5
5
  "sideEffects": [
6
6
  "*.css",
7
7
  "*.woff",
@@ -39,5 +39,5 @@
39
39
  "@cloud-ru/uikit-product-utils": "8.0.1",
40
40
  "classnames": "2.5.1"
41
41
  },
42
- "gitHead": "97f32de112901b4523a7bf7a87bc64aaf21f6c67"
42
+ "gitHead": "14f18bff39619ba8f885fff42922458e7e0ee62c"
43
43
  }
@@ -1,19 +1,23 @@
1
1
  import cn from 'classnames';
2
2
  import { ReactNode } from 'react';
3
3
 
4
- import { extractSupportProps, WithSupportProps } from '@cloud-ru/uikit-product-utils';
4
+ import { extractSupportProps, WithLayoutType, WithSupportProps } from '@cloud-ru/uikit-product-utils';
5
5
 
6
6
  import styles from './styles.module.scss';
7
7
 
8
- export type MainProps = WithSupportProps<{
9
- children: ReactNode;
10
- className?: string;
11
- }>;
8
+ export type MainProps = WithSupportProps<
9
+ WithLayoutType<{
10
+ children: ReactNode;
11
+ className?: string;
12
+ }>
13
+ >;
12
14
 
13
- export function Main({ children, className, ...rest }: MainProps) {
15
+ export function Main({ children, className, layoutType, ...rest }: MainProps) {
14
16
  return (
15
17
  <main className={cn(styles.main, className)} {...extractSupportProps(rest)}>
16
- {children}
18
+ <div className={styles.mainContent} data-layout-type={layoutType}>
19
+ {children}
20
+ </div>
17
21
  </main>
18
22
  );
19
23
  }
@@ -1,6 +1,31 @@
1
+ @use '@sbercloud/figma-tokens-cloud-platform/build/scss/styles-theme-variables' as var;
2
+
1
3
  .main {
2
4
  display: flex;
3
5
  flex: 1;
4
6
  flex-direction: inherit;
7
+ background: var.$sys-neutral-background;
5
8
  }
6
9
 
10
+ .mainContent {
11
+ margin: 0 auto;
12
+ width: 100%;
13
+ max-width: 1440px;
14
+ min-width: 0;
15
+ box-sizing: border-box;
16
+
17
+ &[data-layout-type='desktop'],
18
+ &[data-layout-type='desktopSmall'] {
19
+ padding: 0 var.$dimension-2m;
20
+ }
21
+
22
+ &[data-layout-type='tablet'] {
23
+ max-width: unset;
24
+ padding: 0 var.$dimension-2m;
25
+ }
26
+
27
+ &[data-layout-type='mobile'] {
28
+ max-width: unset;
29
+ padding: 0;
30
+ }
31
+ }
@@ -5,28 +5,21 @@
5
5
  justify-content: center;
6
6
  width: 100%;
7
7
  min-width: 0;
8
- background: var.$sys-neutral-background;
9
8
  }
10
9
 
11
10
  .contentWrapper {
12
11
  width: 100%;
13
- max-width: 1440px;
14
- padding: 0;
12
+ max-width: 1216px;
13
+ padding: 0 var.$dimension-4m;
15
14
  min-width: 0;
16
- box-sizing: border-box;
17
-
18
- &[data-layout-type='desktop'],
19
- &[data-layout-type='desktopSmall'] {
20
- padding: 0 var.$dimension-2m;
21
- }
22
15
 
23
16
  &[data-layout-type='tablet'] {
24
17
  max-width: unset;
25
- padding: 0 var.$dimension-2m;
18
+ padding: 0 var.$dimension-4m;
26
19
  }
27
20
 
28
21
  &[data-layout-type='mobile'] {
29
22
  max-width: unset;
30
- padding: 0;
23
+ padding: 0 var.$dimension-2m;
31
24
  }
32
25
  }