@cloud-ru/ds-bottom-sheet 1.2.1-preview-ac2c37a8.0 → 1.2.2-preview-f367da87.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,10 @@
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
+ ## 1.2.1 (2026-10-01)
7
+
8
+ **Note:** Version bump only for package @ds/bottom-sheet
9
+
6
10
  # 1.2.0 (2026-10-01)
7
11
 
8
12
  ### Features
package/README.md CHANGED
@@ -685,8 +685,8 @@ export function NonModal() {
685
685
  | `onSnapIndexChange` | `((snapIndex: number) => void)` | — | Callback изменения активного snap'а (пересечение swipe-границы или click по UI). <br/> Не вызывается при программной смене controlled `snapIndex`. |
686
686
  | `open` | `boolean` | — | Управление состоянием показан / не показан. |
687
687
  | `rootClassName` | `string` | — | CSS-класс корневого элемента portal'а. |
688
- | `safeAreaBottom` | `boolean` | `true` | Нижний safe-area отступ под iOS home-indicator и Android nav-bar. Размер — токен <br/> `safeArea.paddingBottom` (32px), на устройстве с большим `env(safe-area-inset-bottom)` — значение inset. |
689
- | `safeAreaTop` | `boolean` | `true` | Верхний safe-area отступ под iOS notch / status-bar. Размер — токен `safeArea.paddingTop` (32px), <br/> на устройстве с большим `env(safe-area-inset-top)` — значение inset. Применяется, только когда <br/> sheet раскрыт на полный вьюпорт: у неполного sheet'а верх и так не заходит под notch. |
688
+ | `safeAreaBottom` | `boolean` | `true` | Нижний safe-area отступ под iOS home-indicator и Android nav-bar. Размер — токен <br/> `safeArea.bottom.minHeight`, на устройстве с большим `env(safe-area-inset-bottom)` — значение inset. |
689
+ | `safeAreaTop` | `boolean` | `true` | Верхний safe-area отступ под iOS notch / status-bar. Размер — токен `safeArea.top.minHeight`, <br/> на устройстве с большим `env(safe-area-inset-top)` — значение inset. Применяется, только когда <br/> sheet раскрыт на полный вьюпорт: у неполного sheet'а верх и так не заходит под notch. |
690
690
  | `showBackdrop` | `boolean` | `true` | Отображение тёмной подложки за sheet'ом. При `false` фон не затемняется и click-outside <br/> не закрывает sheet (нет backdrop-узла, по которому ловится клик). |
691
691
  | `slotAfterTitle` | `ReactNode` | — | Slot справа от title (внутри той же строки) — типично `QuestionTooltip`, status badge. |
692
692
  | `slotSecondTitle` | `ReactNode` | — | Slot под подзаголовком — типично `SearchBar`, `SegmentControl`, `Filter`. |
@@ -945,8 +945,8 @@ export function CustomDisableMotions() {
945
945
  | `onSnapIndexChange` | `((snapIndex: number) => void)` | — | Callback изменения активного snap'а (пересечение swipe-границы или click по UI). <br/> Не вызывается при программной смене controlled `snapIndex`. |
946
946
  | `open` | `boolean` | — | Управление состоянием показан / не показан. |
947
947
  | `rootClassName` | `string` | — | CSS-класс корневого элемента portal'а. |
948
- | `safeAreaBottom` | `boolean` | `true` | Нижний safe-area отступ под iOS home-indicator и Android nav-bar. Размер — токен <br/> `safeArea.paddingBottom` (32px), на устройстве с большим `env(safe-area-inset-bottom)` — значение inset. |
949
- | `safeAreaTop` | `boolean` | `true` | Верхний safe-area отступ под iOS notch / status-bar. Размер — токен `safeArea.paddingTop` (32px), <br/> на устройстве с большим `env(safe-area-inset-top)` — значение inset. Применяется, только когда <br/> sheet раскрыт на полный вьюпорт: у неполного sheet'а верх и так не заходит под notch. |
948
+ | `safeAreaBottom` | `boolean` | `true` | Нижний safe-area отступ под iOS home-indicator и Android nav-bar. Размер — токен <br/> `safeArea.bottom.minHeight`, на устройстве с большим `env(safe-area-inset-bottom)` — значение inset. |
949
+ | `safeAreaTop` | `boolean` | `true` | Верхний safe-area отступ под iOS notch / status-bar. Размер — токен `safeArea.top.minHeight`, <br/> на устройстве с большим `env(safe-area-inset-top)` — значение inset. Применяется, только когда <br/> sheet раскрыт на полный вьюпорт: у неполного sheet'а верх и так не заходит под notch. |
950
950
  | `showBackdrop` | `boolean` | `true` | Отображение тёмной подложки за sheet'ом. При `false` фон не затемняется и click-outside <br/> не закрывает sheet (нет backdrop-узла, по которому ловится клик). |
951
951
  | `snapIndex` | `number` | — | Controlled-индекс активного snap'а. Если задан, sheet всегда находится на этом snap'е; <br/> swipe-up/down вызывают `onSnapIndexChange`, но не меняют позицию сами — consumer должен <br/> передать новое значение. |
952
952
  | `snapPoints` | `SnapPoint` | — | Массив фиксированных позиций sheet'а от меньшей к большей. По дефолту `undefined` — <br/> sheet `height: auto` с одним snap'ом по высоте контента. <br/> Пример: `[0.5, 1]` — sheet открывается на половину экрана, drag вверх раскрывает <br/> до full-viewport; drag вниз ниже `0.5` ведёт к закрытию. <br/> Контракт массива (движок не сортирует и не дедуплицирует — порядок и различимость на <br/> стороне потребителя): <br/> - строго по возрастанию: индекс `0` — самая компактная позиция, последний — top / expanded; <br/> - значения должны резолвиться в различные высоты (`['50%', 0.5]` на типичном вьюпорте дадут <br/> одну высоту → дубль-индекс будет недостижим свайпом); <br/> - `'fit-content'` имеет смысл только как ЕДИНСТВЕННЫЙ snap (без `snapPoints`); внутри массива <br/> фиксированных позиций его «контентная» высота не определена. |
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.BottomSheet = BottomSheet;
7
7
  const jsx_runtime_1 = require("react/jsx-runtime");
8
8
  const popup_private_1 = require("@cloud-ru/ds-popup-private");
9
- const classnames_1 = __importDefault(require("classnames"));
10
9
  const react_1 = require("react");
11
10
  const constants_1 = require("../../constants");
12
11
  const BottomSheetCustom_1 = require("../BottomSheetCustom");
@@ -20,7 +19,6 @@ function BottomSheet({ title, slotAfterTitle, subtitle, slotSecondTitle, onBackB
20
19
  className, ...rest }) {
21
20
  const hasHeader = Boolean(title || onBackButtonClick || actionButton || slotAfterTitle || subtitle || slotSecondTitle);
22
21
  const hasMedia = media != null;
23
- const hasFullWidthMediaImage = hasMedia && isMediaProps(media) && (media.kind ?? 'image') === 'image';
24
22
  // aria-labelledby связывает заголовок с dialog'ом; без title имя задаёт потребитель через aria-label.
25
23
  const titleId = (0, react_1.useId)();
26
24
  // Footer: произвольный `footer`-ReactNode (приоритет) либо сборка из слотов кнопок через общий
@@ -35,5 +33,5 @@ className, ...rest }) {
35
33
  return ((0, jsx_runtime_1.jsx)(BottomSheetCustom_1.BottomSheetCustom, { ...rest, swipeEnabled: swipeEnabled, ...(title ? { 'aria-labelledby': titleId } : {}), className: className, disableMotions: false, children: (0, jsx_runtime_1.jsxs)("div", { className: styles_module_scss_1.default.root, children: [hasMedia &&
36
34
  (isMediaProps(media) ? ((0, jsx_runtime_1.jsx)(popup_private_1.PopupMedia, { ...media })) : (
37
35
  // ReactNode-media: тот же data-media-kind-контракт со значением 'custom'.
38
- (0, jsx_runtime_1.jsx)("div", { "data-test-id": constants_1.TEST_IDS.media, "data-media-kind": 'custom', children: media }))), (0, jsx_runtime_1.jsxs)("div", { className: (0, classnames_1.default)(styles_module_scss_1.default.contentBlock, hasFullWidthMediaImage && styles_module_scss_1.default.contentBlockNoTopPadding), children: [hasHeader && ((0, jsx_runtime_1.jsx)(BottomSheetCustom_1.BottomSheetCustom.Header, { title: title, titleId: titleId, slotAfterTitle: slotAfterTitle, subtitle: subtitle, slotSecondTitle: slotSecondTitle, onBackButtonClick: onBackButtonClick, actionButton: actionButton })), withDividers && hasHeader && ((0, jsx_runtime_1.jsx)("div", { className: styles_module_scss_1.default.divider, "data-test-id": constants_1.TEST_IDS.dividerTop, "aria-hidden": true })), (0, jsx_runtime_1.jsx)(BottomSheetCustom_1.BottomSheetCustom.Body, { bodyPadding: bodyPadding, children: content }), withDividers && hasFooter && ((0, jsx_runtime_1.jsx)("div", { className: styles_module_scss_1.default.divider, "data-test-id": constants_1.TEST_IDS.dividerBottom, "aria-hidden": true })), hasFooter && (0, jsx_runtime_1.jsx)(BottomSheetCustom_1.BottomSheetCustom.Footer, { children: footerContent })] })] }) }));
36
+ (0, jsx_runtime_1.jsx)("div", { "data-test-id": constants_1.TEST_IDS.media, "data-media-kind": 'custom', children: media }))), (0, jsx_runtime_1.jsxs)("div", { className: styles_module_scss_1.default.contentBlock, children: [hasHeader && ((0, jsx_runtime_1.jsx)(BottomSheetCustom_1.BottomSheetCustom.Header, { title: title, titleId: titleId, slotAfterTitle: slotAfterTitle, subtitle: subtitle, slotSecondTitle: slotSecondTitle, onBackButtonClick: onBackButtonClick, actionButton: actionButton })), withDividers && hasHeader && ((0, jsx_runtime_1.jsx)("div", { className: styles_module_scss_1.default.divider, "data-test-id": constants_1.TEST_IDS.dividerTop, "aria-hidden": true })), (0, jsx_runtime_1.jsx)(BottomSheetCustom_1.BottomSheetCustom.Body, { bodyPadding: bodyPadding, children: content }), withDividers && hasFooter && ((0, jsx_runtime_1.jsx)("div", { className: styles_module_scss_1.default.divider, "data-test-id": constants_1.TEST_IDS.dividerBottom, "aria-hidden": true })), hasFooter && (0, jsx_runtime_1.jsx)(BottomSheetCustom_1.BottomSheetCustom.Footer, { children: footerContent })] })] }) }));
39
37
  }
@@ -19,9 +19,4 @@
19
19
  flex-direction:column;
20
20
  box-sizing:border-box;
21
21
  min-height:0;
22
- padding-top:var(--sn-bottomSheet-anatomy-container-paddingTop, var(--sn-primitive-dimension-0, 0px));
23
- }
24
-
25
- .contentBlockNoTopPadding{
26
- padding-top:0;
27
22
  }
@@ -31,7 +31,7 @@
31
31
  transform:translateY(100%);
32
32
  display:flex;
33
33
  flex-direction:column;
34
- max-height:calc(100% - max(var(--sn-bottomSheet-anatomy-safeArea-paddingTop, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-top)));
34
+ max-height:calc(100% - max(var(--sn-bottomSheet-anatomy-safeArea-overlay-padding, var(--sn-primitive-dimension-16, 16px)), env(safe-area-inset-top)));
35
35
  transition:transform 0.2s cubic-bezier(0.32, 0.72, 0, 1);
36
36
  }
37
37
  .contentWrapper[data-full-height]{
@@ -54,7 +54,6 @@
54
54
  width:100%;
55
55
  min-height:0;
56
56
  max-height:100%;
57
- padding-top:var(--sn-bottomSheet-anatomy-container-paddingTop, var(--sn-primitive-dimension-0, 0px));
58
57
  border-top-left-radius:var(--sn-bottomSheet-anatomy-container-borderTopLeftRadius, var(--sn-brand-anatomy-radius-window-m, var(--sn-primitive-dimension-4, 4px)));
59
58
  border-top-right-radius:var(--sn-bottomSheet-anatomy-container-borderTopRightRadius, var(--sn-brand-anatomy-radius-window-m, var(--sn-primitive-dimension-4, 4px)));
60
59
  background-color:var(--sn-theme-color-neutral-background1Level, var(--sn-brand-color-neutral-95, var(--sn-brand-palette-gray-95, #ffffff)));
@@ -78,10 +77,10 @@
78
77
  border-top-right-radius:0;
79
78
  }
80
79
  .content[data-safe-area-bottom]{
81
- padding-bottom:max(var(--sn-bottomSheet-anatomy-safeArea-paddingBottom, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-bottom));
80
+ padding-bottom:max(var(--sn-bottomSheet-anatomy-safeArea-bottom-minHeight, var(--sn-primitive-dimension-16, 16px)), env(safe-area-inset-bottom));
82
81
  }
83
82
  .content[data-safe-area-top]{
84
- padding-top:max(var(--sn-bottomSheet-anatomy-safeArea-paddingTop, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-top));
83
+ padding-top:max(var(--sn-bottomSheet-anatomy-safeArea-top-minHeight, var(--sn-primitive-dimension-0, 0px)), env(safe-area-inset-top));
85
84
  }
86
85
 
87
86
  @media (prefers-reduced-motion: reduce){
@@ -19,11 +19,6 @@
19
19
  flex-direction:column;
20
20
  box-sizing:border-box;
21
21
  min-height:0;
22
- padding-top:var(--sn-bottomSheet-anatomy-container-paddingTop, var(--sn-primitive-dimension-0, 0px));
23
- }
24
-
25
- .contentBlockNoTopPadding{
26
- padding-top:0;
27
22
  }
28
23
  .root{
29
24
  pointer-events:none;
@@ -58,7 +53,7 @@
58
53
  transform:translateY(100%);
59
54
  display:flex;
60
55
  flex-direction:column;
61
- max-height:calc(100% - max(var(--sn-bottomSheet-anatomy-safeArea-paddingTop, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-top)));
56
+ max-height:calc(100% - max(var(--sn-bottomSheet-anatomy-safeArea-overlay-padding, var(--sn-primitive-dimension-16, 16px)), env(safe-area-inset-top)));
62
57
  transition:transform 0.2s cubic-bezier(0.32, 0.72, 0, 1);
63
58
  }
64
59
  .contentWrapper[data-full-height]{
@@ -81,7 +76,6 @@
81
76
  width:100%;
82
77
  min-height:0;
83
78
  max-height:100%;
84
- padding-top:var(--sn-bottomSheet-anatomy-container-paddingTop, var(--sn-primitive-dimension-0, 0px));
85
79
  border-top-left-radius:var(--sn-bottomSheet-anatomy-container-borderTopLeftRadius, var(--sn-brand-anatomy-radius-window-m, var(--sn-primitive-dimension-4, 4px)));
86
80
  border-top-right-radius:var(--sn-bottomSheet-anatomy-container-borderTopRightRadius, var(--sn-brand-anatomy-radius-window-m, var(--sn-primitive-dimension-4, 4px)));
87
81
  background-color:var(--sn-theme-color-neutral-background1Level, var(--sn-brand-color-neutral-95, var(--sn-brand-palette-gray-95, #ffffff)));
@@ -105,10 +99,10 @@
105
99
  border-top-right-radius:0;
106
100
  }
107
101
  .content[data-safe-area-bottom]{
108
- padding-bottom:max(var(--sn-bottomSheet-anatomy-safeArea-paddingBottom, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-bottom));
102
+ padding-bottom:max(var(--sn-bottomSheet-anatomy-safeArea-bottom-minHeight, var(--sn-primitive-dimension-16, 16px)), env(safe-area-inset-bottom));
109
103
  }
110
104
  .content[data-safe-area-top]{
111
- padding-top:max(var(--sn-bottomSheet-anatomy-safeArea-paddingTop, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-top));
105
+ padding-top:max(var(--sn-bottomSheet-anatomy-safeArea-top-minHeight, var(--sn-primitive-dimension-0, 0px)), env(safe-area-inset-top));
112
106
  }
113
107
 
114
108
  @media (prefers-reduced-motion: reduce){
@@ -74,7 +74,7 @@ export type BottomSheetCustomProps = WithSupportProps<PropsWithChildren<{
74
74
  */
75
75
  closeOnPopstate?: boolean;
76
76
  /**
77
- * Верхний safe-area отступ под iOS notch / status-bar. Размер — токен `safeArea.paddingTop` (32px),
77
+ * Верхний safe-area отступ под iOS notch / status-bar. Размер — токен `safeArea.top.minHeight`,
78
78
  * на устройстве с большим `env(safe-area-inset-top)` — значение inset. Применяется, только когда
79
79
  * sheet раскрыт на полный вьюпорт: у неполного sheet'а верх и так не заходит под notch.
80
80
  * @default true
@@ -82,7 +82,7 @@ export type BottomSheetCustomProps = WithSupportProps<PropsWithChildren<{
82
82
  safeAreaTop?: boolean;
83
83
  /**
84
84
  * Нижний safe-area отступ под iOS home-indicator и Android nav-bar. Размер — токен
85
- * `safeArea.paddingBottom` (32px), на устройстве с большим `env(safe-area-inset-bottom)` — значение inset.
85
+ * `safeArea.bottom.minHeight`, на устройстве с большим `env(safe-area-inset-bottom)` — значение inset.
86
86
  * @default true
87
87
  */
88
88
  safeAreaBottom?: boolean;
@@ -1,6 +1,5 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { FooterActions, PopupMedia } from '@cloud-ru/ds-popup-private';
3
- import cn from 'classnames';
4
3
  import { isValidElement, useId } from 'react';
5
4
  import { TEST_IDS } from '../../constants.js';
6
5
  import { BottomSheetCustom } from '../BottomSheetCustom/index.js';
@@ -14,7 +13,6 @@ export function BottomSheet({ title, slotAfterTitle, subtitle, slotSecondTitle,
14
13
  className, ...rest }) {
15
14
  const hasHeader = Boolean(title || onBackButtonClick || actionButton || slotAfterTitle || subtitle || slotSecondTitle);
16
15
  const hasMedia = media != null;
17
- const hasFullWidthMediaImage = hasMedia && isMediaProps(media) && (media.kind ?? 'image') === 'image';
18
16
  // aria-labelledby связывает заголовок с dialog'ом; без title имя задаёт потребитель через aria-label.
19
17
  const titleId = useId();
20
18
  // Footer: произвольный `footer`-ReactNode (приоритет) либо сборка из слотов кнопок через общий
@@ -29,5 +27,5 @@ className, ...rest }) {
29
27
  return (_jsx(BottomSheetCustom, { ...rest, swipeEnabled: swipeEnabled, ...(title ? { 'aria-labelledby': titleId } : {}), className: className, disableMotions: false, children: _jsxs("div", { className: styles.root, children: [hasMedia &&
30
28
  (isMediaProps(media) ? (_jsx(PopupMedia, { ...media })) : (
31
29
  // ReactNode-media: тот же data-media-kind-контракт со значением 'custom'.
32
- _jsx("div", { "data-test-id": TEST_IDS.media, "data-media-kind": 'custom', children: media }))), _jsxs("div", { className: cn(styles.contentBlock, hasFullWidthMediaImage && styles.contentBlockNoTopPadding), children: [hasHeader && (_jsx(BottomSheetCustom.Header, { title: title, titleId: titleId, slotAfterTitle: slotAfterTitle, subtitle: subtitle, slotSecondTitle: slotSecondTitle, onBackButtonClick: onBackButtonClick, actionButton: actionButton })), withDividers && hasHeader && (_jsx("div", { className: styles.divider, "data-test-id": TEST_IDS.dividerTop, "aria-hidden": true })), _jsx(BottomSheetCustom.Body, { bodyPadding: bodyPadding, children: content }), withDividers && hasFooter && (_jsx("div", { className: styles.divider, "data-test-id": TEST_IDS.dividerBottom, "aria-hidden": true })), hasFooter && _jsx(BottomSheetCustom.Footer, { children: footerContent })] })] }) }));
30
+ _jsx("div", { "data-test-id": TEST_IDS.media, "data-media-kind": 'custom', children: media }))), _jsxs("div", { className: styles.contentBlock, children: [hasHeader && (_jsx(BottomSheetCustom.Header, { title: title, titleId: titleId, slotAfterTitle: slotAfterTitle, subtitle: subtitle, slotSecondTitle: slotSecondTitle, onBackButtonClick: onBackButtonClick, actionButton: actionButton })), withDividers && hasHeader && (_jsx("div", { className: styles.divider, "data-test-id": TEST_IDS.dividerTop, "aria-hidden": true })), _jsx(BottomSheetCustom.Body, { bodyPadding: bodyPadding, children: content }), withDividers && hasFooter && (_jsx("div", { className: styles.divider, "data-test-id": TEST_IDS.dividerBottom, "aria-hidden": true })), hasFooter && _jsx(BottomSheetCustom.Footer, { children: footerContent })] })] }) }));
33
31
  }
@@ -19,9 +19,4 @@
19
19
  flex-direction:column;
20
20
  box-sizing:border-box;
21
21
  min-height:0;
22
- padding-top:var(--sn-bottomSheet-anatomy-container-paddingTop, var(--sn-primitive-dimension-0, 0px));
23
- }
24
-
25
- .contentBlockNoTopPadding{
26
- padding-top:0;
27
22
  }
@@ -31,7 +31,7 @@
31
31
  transform:translateY(100%);
32
32
  display:flex;
33
33
  flex-direction:column;
34
- max-height:calc(100% - max(var(--sn-bottomSheet-anatomy-safeArea-paddingTop, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-top)));
34
+ max-height:calc(100% - max(var(--sn-bottomSheet-anatomy-safeArea-overlay-padding, var(--sn-primitive-dimension-16, 16px)), env(safe-area-inset-top)));
35
35
  transition:transform 0.2s cubic-bezier(0.32, 0.72, 0, 1);
36
36
  }
37
37
  .contentWrapper[data-full-height]{
@@ -54,7 +54,6 @@
54
54
  width:100%;
55
55
  min-height:0;
56
56
  max-height:100%;
57
- padding-top:var(--sn-bottomSheet-anatomy-container-paddingTop, var(--sn-primitive-dimension-0, 0px));
58
57
  border-top-left-radius:var(--sn-bottomSheet-anatomy-container-borderTopLeftRadius, var(--sn-brand-anatomy-radius-window-m, var(--sn-primitive-dimension-4, 4px)));
59
58
  border-top-right-radius:var(--sn-bottomSheet-anatomy-container-borderTopRightRadius, var(--sn-brand-anatomy-radius-window-m, var(--sn-primitive-dimension-4, 4px)));
60
59
  background-color:var(--sn-theme-color-neutral-background1Level, var(--sn-brand-color-neutral-95, var(--sn-brand-palette-gray-95, #ffffff)));
@@ -78,10 +77,10 @@
78
77
  border-top-right-radius:0;
79
78
  }
80
79
  .content[data-safe-area-bottom]{
81
- padding-bottom:max(var(--sn-bottomSheet-anatomy-safeArea-paddingBottom, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-bottom));
80
+ padding-bottom:max(var(--sn-bottomSheet-anatomy-safeArea-bottom-minHeight, var(--sn-primitive-dimension-16, 16px)), env(safe-area-inset-bottom));
82
81
  }
83
82
  .content[data-safe-area-top]{
84
- padding-top:max(var(--sn-bottomSheet-anatomy-safeArea-paddingTop, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-top));
83
+ padding-top:max(var(--sn-bottomSheet-anatomy-safeArea-top-minHeight, var(--sn-primitive-dimension-0, 0px)), env(safe-area-inset-top));
85
84
  }
86
85
 
87
86
  @media (prefers-reduced-motion: reduce){
@@ -19,11 +19,6 @@
19
19
  flex-direction:column;
20
20
  box-sizing:border-box;
21
21
  min-height:0;
22
- padding-top:var(--sn-bottomSheet-anatomy-container-paddingTop, var(--sn-primitive-dimension-0, 0px));
23
- }
24
-
25
- .contentBlockNoTopPadding{
26
- padding-top:0;
27
22
  }
28
23
  .root{
29
24
  pointer-events:none;
@@ -58,7 +53,7 @@
58
53
  transform:translateY(100%);
59
54
  display:flex;
60
55
  flex-direction:column;
61
- max-height:calc(100% - max(var(--sn-bottomSheet-anatomy-safeArea-paddingTop, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-top)));
56
+ max-height:calc(100% - max(var(--sn-bottomSheet-anatomy-safeArea-overlay-padding, var(--sn-primitive-dimension-16, 16px)), env(safe-area-inset-top)));
62
57
  transition:transform 0.2s cubic-bezier(0.32, 0.72, 0, 1);
63
58
  }
64
59
  .contentWrapper[data-full-height]{
@@ -81,7 +76,6 @@
81
76
  width:100%;
82
77
  min-height:0;
83
78
  max-height:100%;
84
- padding-top:var(--sn-bottomSheet-anatomy-container-paddingTop, var(--sn-primitive-dimension-0, 0px));
85
79
  border-top-left-radius:var(--sn-bottomSheet-anatomy-container-borderTopLeftRadius, var(--sn-brand-anatomy-radius-window-m, var(--sn-primitive-dimension-4, 4px)));
86
80
  border-top-right-radius:var(--sn-bottomSheet-anatomy-container-borderTopRightRadius, var(--sn-brand-anatomy-radius-window-m, var(--sn-primitive-dimension-4, 4px)));
87
81
  background-color:var(--sn-theme-color-neutral-background1Level, var(--sn-brand-color-neutral-95, var(--sn-brand-palette-gray-95, #ffffff)));
@@ -105,10 +99,10 @@
105
99
  border-top-right-radius:0;
106
100
  }
107
101
  .content[data-safe-area-bottom]{
108
- padding-bottom:max(var(--sn-bottomSheet-anatomy-safeArea-paddingBottom, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-bottom));
102
+ padding-bottom:max(var(--sn-bottomSheet-anatomy-safeArea-bottom-minHeight, var(--sn-primitive-dimension-16, 16px)), env(safe-area-inset-bottom));
109
103
  }
110
104
  .content[data-safe-area-top]{
111
- padding-top:max(var(--sn-bottomSheet-anatomy-safeArea-paddingTop, var(--sn-primitive-dimension-32, 32px)), env(safe-area-inset-top));
105
+ padding-top:max(var(--sn-bottomSheet-anatomy-safeArea-top-minHeight, var(--sn-primitive-dimension-0, 0px)), env(safe-area-inset-top));
112
106
  }
113
107
 
114
108
  @media (prefers-reduced-motion: reduce){
@@ -74,7 +74,7 @@ export type BottomSheetCustomProps = WithSupportProps<PropsWithChildren<{
74
74
  */
75
75
  closeOnPopstate?: boolean;
76
76
  /**
77
- * Верхний safe-area отступ под iOS notch / status-bar. Размер — токен `safeArea.paddingTop` (32px),
77
+ * Верхний safe-area отступ под iOS notch / status-bar. Размер — токен `safeArea.top.minHeight`,
78
78
  * на устройстве с большим `env(safe-area-inset-top)` — значение inset. Применяется, только когда
79
79
  * sheet раскрыт на полный вьюпорт: у неполного sheet'а верх и так не заходит под notch.
80
80
  * @default true
@@ -82,7 +82,7 @@ export type BottomSheetCustomProps = WithSupportProps<PropsWithChildren<{
82
82
  safeAreaTop?: boolean;
83
83
  /**
84
84
  * Нижний safe-area отступ под iOS home-indicator и Android nav-bar. Размер — токен
85
- * `safeArea.paddingBottom` (32px), на устройстве с большим `env(safe-area-inset-bottom)` — значение inset.
85
+ * `safeArea.bottom.minHeight`, на устройстве с большим `env(safe-area-inset-bottom)` — значение inset.
86
86
  * @default true
87
87
  */
88
88
  safeAreaBottom?: boolean;