@alfalab/core-components-universal-modal 3.2.5 → 3.2.6-alfasans

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.
Files changed (236) hide show
  1. package/Context.d.ts +1 -1
  2. package/Context.js +1 -1
  3. package/Context.js.map +1 -1
  4. package/components/base-content/index.css +1 -1
  5. package/components/base-content/index.module.css.js +1 -1
  6. package/components/base-footer/index.css +3 -3
  7. package/components/base-footer/index.module.css.js +1 -1
  8. package/components/base-header/index.css +4 -4
  9. package/components/base-header/index.module.css.js +1 -1
  10. package/cssm/Context.d.ts +1 -1
  11. package/cssm/Context.js +1 -1
  12. package/cssm/Context.js.map +1 -1
  13. package/cssm/desktop/Component.desktop.d.ts +1 -1
  14. package/cssm/desktop/components/center-modal/center-modal.js +2 -2
  15. package/cssm/desktop/components/center-modal/center-modal.js.map +1 -1
  16. package/cssm/desktop/components/footer/index.d.ts +2 -7
  17. package/cssm/desktop/components/footer/index.js.map +1 -1
  18. package/cssm/desktop/components/header/desktop.module.css +11 -6
  19. package/cssm/desktop/components/modal-content/modal-content.js +2 -9
  20. package/cssm/desktop/components/modal-content/modal-content.js.map +1 -1
  21. package/cssm/desktop/components/side-modal/side-modal.js +2 -2
  22. package/cssm/desktop/components/side-modal/side-modal.js.map +1 -1
  23. package/cssm/desktop/types/props.d.ts +1 -1
  24. package/cssm/mobile/components/header/index.module.css +9 -6
  25. package/cssm/mobile/types/props.d.ts +1 -1
  26. package/desktop/Component.desktop.d.ts +1 -1
  27. package/desktop/components/center-modal/center-modal.js +2 -2
  28. package/desktop/components/center-modal/center-modal.js.map +1 -1
  29. package/desktop/components/center-modal/index.css +1104 -1104
  30. package/desktop/components/center-modal/index.module.css.js +1 -1
  31. package/desktop/components/center-modal/transitions/safari-transitions.css +7 -7
  32. package/desktop/components/center-modal/transitions/safari-transitions.module.css.js +1 -1
  33. package/desktop/components/center-modal/transitions/transitions.css +7 -7
  34. package/desktop/components/center-modal/transitions/transitions.module.css.js +1 -1
  35. package/desktop/components/footer/desktop.css +1 -1
  36. package/desktop/components/footer/desktop.module.css.js +1 -1
  37. package/desktop/components/footer/index.d.ts +2 -7
  38. package/desktop/components/footer/index.js.map +1 -1
  39. package/desktop/components/footer/layout.css +9 -9
  40. package/desktop/components/footer/layout.module.css.js +1 -1
  41. package/desktop/components/header/desktop.css +16 -11
  42. package/desktop/components/header/desktop.module.css.js +1 -1
  43. package/desktop/components/modal-content/modal-content.css +4 -4
  44. package/desktop/components/modal-content/modal-content.js +2 -9
  45. package/desktop/components/modal-content/modal-content.js.map +1 -1
  46. package/desktop/components/modal-content/modal-content.module.css.js +1 -1
  47. package/desktop/components/side-modal/index.css +1106 -1106
  48. package/desktop/components/side-modal/index.module.css.js +1 -1
  49. package/desktop/components/side-modal/side-modal.js +2 -2
  50. package/desktop/components/side-modal/side-modal.js.map +1 -1
  51. package/desktop/components/side-modal/transitions/transitions.css +71 -71
  52. package/desktop/components/side-modal/transitions/transitions.module.css.js +1 -1
  53. package/desktop/styles/transitions/full-size-backdrop-transitions.css +13 -13
  54. package/desktop/styles/transitions/full-size-backdrop-transitions.module.css.js +1 -1
  55. package/desktop/styles/transitions/full-size-vertical-bottom-transitions.css +7 -7
  56. package/desktop/styles/transitions/full-size-vertical-bottom-transitions.module.css.js +1 -1
  57. package/desktop/styles/transitions/full-size-vertical-center-transitions.css +7 -7
  58. package/desktop/styles/transitions/full-size-vertical-center-transitions.module.css.js +1 -1
  59. package/desktop/styles/transitions/full-size-vertical-top-transitions.css +7 -7
  60. package/desktop/styles/transitions/full-size-vertical-top-transitions.module.css.js +1 -1
  61. package/desktop/types/props.d.ts +1 -1
  62. package/esm/Context.d.ts +1 -1
  63. package/esm/Context.js +1 -1
  64. package/esm/Context.js.map +1 -1
  65. package/esm/components/base-content/index.css +1 -1
  66. package/esm/components/base-content/index.module.css.js +1 -1
  67. package/esm/components/base-footer/index.css +3 -3
  68. package/esm/components/base-footer/index.module.css.js +1 -1
  69. package/esm/components/base-header/index.css +4 -4
  70. package/esm/components/base-header/index.module.css.js +1 -1
  71. package/esm/desktop/Component.desktop.d.ts +1 -1
  72. package/esm/desktop/components/center-modal/center-modal.js +2 -2
  73. package/esm/desktop/components/center-modal/center-modal.js.map +1 -1
  74. package/esm/desktop/components/center-modal/index.css +1104 -1104
  75. package/esm/desktop/components/center-modal/index.module.css.js +1 -1
  76. package/esm/desktop/components/center-modal/transitions/safari-transitions.css +7 -7
  77. package/esm/desktop/components/center-modal/transitions/safari-transitions.module.css.js +1 -1
  78. package/esm/desktop/components/center-modal/transitions/transitions.css +7 -7
  79. package/esm/desktop/components/center-modal/transitions/transitions.module.css.js +1 -1
  80. package/esm/desktop/components/footer/desktop.css +1 -1
  81. package/esm/desktop/components/footer/desktop.module.css.js +1 -1
  82. package/esm/desktop/components/footer/index.d.ts +2 -7
  83. package/esm/desktop/components/footer/index.js.map +1 -1
  84. package/esm/desktop/components/footer/layout.css +9 -9
  85. package/esm/desktop/components/footer/layout.module.css.js +1 -1
  86. package/esm/desktop/components/header/desktop.css +16 -11
  87. package/esm/desktop/components/header/desktop.module.css.js +1 -1
  88. package/esm/desktop/components/modal-content/modal-content.css +4 -4
  89. package/esm/desktop/components/modal-content/modal-content.js +2 -8
  90. package/esm/desktop/components/modal-content/modal-content.js.map +1 -1
  91. package/esm/desktop/components/modal-content/modal-content.module.css.js +1 -1
  92. package/esm/desktop/components/side-modal/index.css +1106 -1106
  93. package/esm/desktop/components/side-modal/index.module.css.js +1 -1
  94. package/esm/desktop/components/side-modal/side-modal.js +2 -2
  95. package/esm/desktop/components/side-modal/side-modal.js.map +1 -1
  96. package/esm/desktop/components/side-modal/transitions/transitions.css +71 -71
  97. package/esm/desktop/components/side-modal/transitions/transitions.module.css.js +1 -1
  98. package/esm/desktop/styles/transitions/full-size-backdrop-transitions.css +13 -13
  99. package/esm/desktop/styles/transitions/full-size-backdrop-transitions.module.css.js +1 -1
  100. package/esm/desktop/styles/transitions/full-size-vertical-bottom-transitions.css +7 -7
  101. package/esm/desktop/styles/transitions/full-size-vertical-bottom-transitions.module.css.js +1 -1
  102. package/esm/desktop/styles/transitions/full-size-vertical-center-transitions.css +7 -7
  103. package/esm/desktop/styles/transitions/full-size-vertical-center-transitions.module.css.js +1 -1
  104. package/esm/desktop/styles/transitions/full-size-vertical-top-transitions.css +7 -7
  105. package/esm/desktop/styles/transitions/full-size-vertical-top-transitions.module.css.js +1 -1
  106. package/esm/desktop/types/props.d.ts +1 -1
  107. package/esm/mobile/components/content/index.css +3 -3
  108. package/esm/mobile/components/content/index.module.css.js +1 -1
  109. package/esm/mobile/components/footer/index.css +2 -2
  110. package/esm/mobile/components/footer/index.module.css.js +1 -1
  111. package/esm/mobile/components/footer/layout.mobile.css +9 -9
  112. package/esm/mobile/components/footer/layout.mobile.module.css.js +1 -1
  113. package/esm/mobile/components/header/index.css +12 -9
  114. package/esm/mobile/components/header/index.module.css.js +1 -1
  115. package/esm/mobile/mobile.css +3 -3
  116. package/esm/mobile/mobile.module.css.js +1 -1
  117. package/esm/mobile/transitions/right-side-transitions.mobile.css +7 -7
  118. package/esm/mobile/transitions/right-side-transitions.mobile.module.css.js +1 -1
  119. package/esm/mobile/transitions/transitions.mobile.css +7 -7
  120. package/esm/mobile/transitions/transitions.mobile.module.css.js +1 -1
  121. package/esm/mobile/types/props.d.ts +1 -1
  122. package/mobile/components/content/index.css +3 -3
  123. package/mobile/components/content/index.module.css.js +1 -1
  124. package/mobile/components/footer/index.css +2 -2
  125. package/mobile/components/footer/index.module.css.js +1 -1
  126. package/mobile/components/footer/layout.mobile.css +9 -9
  127. package/mobile/components/footer/layout.mobile.module.css.js +1 -1
  128. package/mobile/components/header/index.css +12 -9
  129. package/mobile/components/header/index.module.css.js +1 -1
  130. package/mobile/mobile.css +3 -3
  131. package/mobile/mobile.module.css.js +1 -1
  132. package/mobile/transitions/right-side-transitions.mobile.css +7 -7
  133. package/mobile/transitions/right-side-transitions.mobile.module.css.js +1 -1
  134. package/mobile/transitions/transitions.mobile.css +7 -7
  135. package/mobile/transitions/transitions.mobile.module.css.js +1 -1
  136. package/mobile/types/props.d.ts +1 -1
  137. package/modern/Context.d.ts +1 -1
  138. package/modern/Context.js +1 -1
  139. package/modern/Context.js.map +1 -1
  140. package/modern/components/base-content/index.css +1 -1
  141. package/modern/components/base-content/index.module.css.js +1 -1
  142. package/modern/components/base-footer/index.css +3 -3
  143. package/modern/components/base-footer/index.module.css.js +1 -1
  144. package/modern/components/base-header/index.css +4 -4
  145. package/modern/components/base-header/index.module.css.js +1 -1
  146. package/modern/desktop/Component.desktop.d.ts +1 -1
  147. package/modern/desktop/components/center-modal/center-modal.js +2 -2
  148. package/modern/desktop/components/center-modal/center-modal.js.map +1 -1
  149. package/modern/desktop/components/center-modal/index.css +1104 -1104
  150. package/modern/desktop/components/center-modal/index.module.css.js +1 -1
  151. package/modern/desktop/components/center-modal/transitions/safari-transitions.css +7 -7
  152. package/modern/desktop/components/center-modal/transitions/safari-transitions.module.css.js +1 -1
  153. package/modern/desktop/components/center-modal/transitions/transitions.css +7 -7
  154. package/modern/desktop/components/center-modal/transitions/transitions.module.css.js +1 -1
  155. package/modern/desktop/components/footer/desktop.css +1 -1
  156. package/modern/desktop/components/footer/desktop.module.css.js +1 -1
  157. package/modern/desktop/components/footer/index.d.ts +2 -7
  158. package/modern/desktop/components/footer/index.js.map +1 -1
  159. package/modern/desktop/components/footer/layout.css +9 -9
  160. package/modern/desktop/components/footer/layout.module.css.js +1 -1
  161. package/modern/desktop/components/header/desktop.css +16 -11
  162. package/modern/desktop/components/header/desktop.module.css.js +1 -1
  163. package/modern/desktop/components/modal-content/modal-content.css +4 -4
  164. package/modern/desktop/components/modal-content/modal-content.js +2 -8
  165. package/modern/desktop/components/modal-content/modal-content.js.map +1 -1
  166. package/modern/desktop/components/modal-content/modal-content.module.css.js +1 -1
  167. package/modern/desktop/components/side-modal/index.css +1106 -1106
  168. package/modern/desktop/components/side-modal/index.module.css.js +1 -1
  169. package/modern/desktop/components/side-modal/side-modal.js +2 -2
  170. package/modern/desktop/components/side-modal/side-modal.js.map +1 -1
  171. package/modern/desktop/components/side-modal/transitions/transitions.css +71 -71
  172. package/modern/desktop/components/side-modal/transitions/transitions.module.css.js +1 -1
  173. package/modern/desktop/styles/transitions/full-size-backdrop-transitions.css +13 -13
  174. package/modern/desktop/styles/transitions/full-size-backdrop-transitions.module.css.js +1 -1
  175. package/modern/desktop/styles/transitions/full-size-vertical-bottom-transitions.css +7 -7
  176. package/modern/desktop/styles/transitions/full-size-vertical-bottom-transitions.module.css.js +1 -1
  177. package/modern/desktop/styles/transitions/full-size-vertical-center-transitions.css +7 -7
  178. package/modern/desktop/styles/transitions/full-size-vertical-center-transitions.module.css.js +1 -1
  179. package/modern/desktop/styles/transitions/full-size-vertical-top-transitions.css +7 -7
  180. package/modern/desktop/styles/transitions/full-size-vertical-top-transitions.module.css.js +1 -1
  181. package/modern/desktop/types/props.d.ts +1 -1
  182. package/modern/mobile/components/content/index.css +3 -3
  183. package/modern/mobile/components/content/index.module.css.js +1 -1
  184. package/modern/mobile/components/footer/index.css +2 -2
  185. package/modern/mobile/components/footer/index.module.css.js +1 -1
  186. package/modern/mobile/components/footer/layout.mobile.css +9 -9
  187. package/modern/mobile/components/footer/layout.mobile.module.css.js +1 -1
  188. package/modern/mobile/components/header/index.css +12 -9
  189. package/modern/mobile/components/header/index.module.css.js +1 -1
  190. package/modern/mobile/mobile.css +3 -3
  191. package/modern/mobile/mobile.module.css.js +1 -1
  192. package/modern/mobile/transitions/right-side-transitions.mobile.css +7 -7
  193. package/modern/mobile/transitions/right-side-transitions.mobile.module.css.js +1 -1
  194. package/modern/mobile/transitions/transitions.mobile.css +7 -7
  195. package/modern/mobile/transitions/transitions.mobile.module.css.js +1 -1
  196. package/modern/mobile/types/props.d.ts +1 -1
  197. package/moderncssm/Context.d.ts +1 -1
  198. package/moderncssm/Context.js +1 -1
  199. package/moderncssm/Context.js.map +1 -1
  200. package/moderncssm/desktop/Component.desktop.d.ts +1 -1
  201. package/moderncssm/desktop/components/center-modal/center-modal.js +2 -2
  202. package/moderncssm/desktop/components/center-modal/center-modal.js.map +1 -1
  203. package/moderncssm/desktop/components/footer/index.d.ts +2 -7
  204. package/moderncssm/desktop/components/footer/index.js.map +1 -1
  205. package/moderncssm/desktop/components/header/desktop.module.css +8 -4
  206. package/moderncssm/desktop/components/modal-content/modal-content.js +2 -8
  207. package/moderncssm/desktop/components/modal-content/modal-content.js.map +1 -1
  208. package/moderncssm/desktop/components/side-modal/side-modal.js +2 -2
  209. package/moderncssm/desktop/components/side-modal/side-modal.js.map +1 -1
  210. package/moderncssm/desktop/types/props.d.ts +1 -1
  211. package/moderncssm/mobile/components/header/index.module.css +6 -4
  212. package/moderncssm/mobile/types/props.d.ts +1 -1
  213. package/package.json +9 -9
  214. package/src/Context.ts +1 -1
  215. package/src/desktop/components/center-modal/center-modal.tsx +5 -3
  216. package/src/desktop/components/footer/index.tsx +1 -6
  217. package/src/desktop/components/modal-content/modal-content.tsx +1 -9
  218. package/src/desktop/components/side-modal/side-modal.tsx +5 -3
  219. package/src/desktop/types/props.ts +1 -0
  220. package/src/mobile/types/props.ts +2 -0
  221. package/cssm/desktop/hooks/use-modal-highlighted.d.ts +0 -13
  222. package/cssm/desktop/hooks/use-modal-highlighted.js +0 -57
  223. package/cssm/desktop/hooks/use-modal-highlighted.js.map +0 -1
  224. package/desktop/hooks/use-modal-highlighted.d.ts +0 -13
  225. package/desktop/hooks/use-modal-highlighted.js +0 -57
  226. package/desktop/hooks/use-modal-highlighted.js.map +0 -1
  227. package/esm/desktop/hooks/use-modal-highlighted.d.ts +0 -13
  228. package/esm/desktop/hooks/use-modal-highlighted.js +0 -53
  229. package/esm/desktop/hooks/use-modal-highlighted.js.map +0 -1
  230. package/modern/desktop/hooks/use-modal-highlighted.d.ts +0 -13
  231. package/modern/desktop/hooks/use-modal-highlighted.js +0 -52
  232. package/modern/desktop/hooks/use-modal-highlighted.js.map +0 -1
  233. package/moderncssm/desktop/hooks/use-modal-highlighted.d.ts +0 -13
  234. package/moderncssm/desktop/hooks/use-modal-highlighted.js +0 -52
  235. package/moderncssm/desktop/hooks/use-modal-highlighted.js.map +0 -1
  236. package/src/desktop/hooks/use-modal-highlighted.ts +0 -75
@@ -1 +1 @@
1
- {"version":3,"file":"Context.js","sources":["../src/Context.ts"],"sourcesContent":["import { BaseModalContext } from '@alfalab/core-components-base-modal';\n\n/**\n * @deprecated Некоторые параметры могут не соответствовать реальным состояниям компонента\n */\nexport const ModalContext = BaseModalContext;\n"],"names":[],"mappings":";;AAEA;;AAEG;AACI,IAAM,YAAY,GAAG;;;;"}
1
+ {"version":3,"file":"Context.js","sources":["../src/Context.ts"],"sourcesContent":["import { BaseModalContext } from '@alfalab/core-components-base-modal';\n\n/**\n * @deprecated В будущем контекст будет удалён. Обрабатывайте состояния компонента самостоятельно.\n */\nexport const ModalContext = BaseModalContext;\n"],"names":[],"mappings":";;AAEA;;AAEG;AACI,IAAM,YAAY,GAAG;;;;"}
@@ -1,7 +1,7 @@
1
1
  :root {
2
2
  --gap-32: 32px;
3
3
  }
4
- .universal-modal__content_1e00w {
4
+ .universal-modal__content_ctmlq {
5
5
  position: relative;
6
6
  box-sizing: border-box;
7
7
  width: 100%;
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- var styles = {"content":"universal-modal__content_1e00w"};
3
+ var styles = {"content":"universal-modal__content_ctmlq"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -11,7 +11,7 @@
11
11
  --universal-modal-footer-highlight-background: var(--color-light-modal-bg-primary);
12
12
  --universal-modal-footer-highlight-box-shadow: 0 -1px 0 0 var(--color-light-neutral-300);
13
13
  }
14
- .universal-modal__footer_agber {
14
+ .universal-modal__footer_y2hw6 {
15
15
  width: 100%;
16
16
  box-sizing: border-box;
17
17
  transition:
@@ -19,12 +19,12 @@
19
19
  background 0.2s ease;
20
20
  padding: var(--gap-16) var(--gap-32) var(--gap-32);
21
21
  }
22
- .universal-modal__sticky_agber {
22
+ .universal-modal__sticky_y2hw6 {
23
23
  background: var(--universal-modal-footer-background);
24
24
  position: sticky;
25
25
  z-index: 1;
26
26
  }
27
- .universal-modal__highlighted_agber {
27
+ .universal-modal__highlighted_y2hw6 {
28
28
  background: var(--universal-modal-footer-highlight-background);
29
29
  box-shadow: var(--universal-modal-footer-highlight-box-shadow);
30
30
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- var styles = {"footer":"universal-modal__footer_agber","sticky":"universal-modal__sticky_agber","highlighted":"universal-modal__highlighted_agber"};
3
+ var styles = {"footer":"universal-modal__footer_y2hw6","sticky":"universal-modal__sticky_y2hw6","highlighted":"universal-modal__highlighted_y2hw6"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -10,22 +10,22 @@
10
10
  --universal-modal-header-highlight-background: var(--color-light-modal-bg-primary);
11
11
  --universal-modal-header-highlight-box-shadow: 0 1px 0 0 var(--color-light-neutral-300);
12
12
  }
13
- .universal-modal__header_vw52s {
13
+ .universal-modal__header_49r0q {
14
14
  width: 100%;
15
15
  box-sizing: border-box;
16
16
  transition:
17
17
  box-shadow 0.2s ease,
18
18
  background 0.2s ease;
19
19
  }
20
- .universal-modal__header_vw52s.universal-modal__highlighted_vw52s {
20
+ .universal-modal__header_49r0q.universal-modal__highlighted_49r0q {
21
21
  background: var(--universal-modal-header-highlight-background);
22
22
  box-shadow: var(--universal-modal-header-highlight-box-shadow);
23
23
  }
24
- .universal-modal__header_vw52s.universal-modal__sticky_vw52s {
24
+ .universal-modal__header_49r0q.universal-modal__sticky_49r0q {
25
25
  position: sticky;
26
26
  top: var(--gap-0);
27
27
  z-index: 1;
28
28
  }
29
- .universal-modal__header_vw52s.universal-modal__sticky_vw52s.universal-modal__hasContent_vw52s {
29
+ .universal-modal__header_49r0q.universal-modal__sticky_49r0q.universal-modal__hasContent_49r0q {
30
30
  background: var(--universal-modal-header-background);
31
31
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- var styles = {"header":"universal-modal__header_vw52s","highlighted":"universal-modal__highlighted_vw52s","sticky":"universal-modal__sticky_vw52s","hasContent":"universal-modal__hasContent_vw52s"};
3
+ var styles = {"header":"universal-modal__header_49r0q","highlighted":"universal-modal__highlighted_49r0q","sticky":"universal-modal__sticky_49r0q","hasContent":"universal-modal__hasContent_49r0q"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -4,5 +4,5 @@ export declare const UniversalModalDesktopComponent: React.ForwardRefExoticCompo
4
4
  export declare const UniversalModalDesktop: React.ForwardRefExoticComponent<UniversalModalDesktopProps & React.RefAttributes<HTMLDivElement>> & {
5
5
  Header: React.ForwardRefExoticComponent<import("./components/header").HeaderDesktopProps & React.RefAttributes<HTMLDivElement>>;
6
6
  Content: React.FC<import("../components/base-content").ContentProps>;
7
- Footer: React.ForwardRefExoticComponent<import("./components/footer").FooterDesktopProps & React.RefAttributes<HTMLDivElement>>;
7
+ Footer: React.ForwardRefExoticComponent<import("../components/base-footer").FooterProps & React.RefAttributes<HTMLDivElement>>;
8
8
  };
@@ -21,7 +21,7 @@ import transitions from './transitions/transitions.module.css.js';
21
21
  var transitionProps = isMacOS() && isSafari() ? safariTransitions : transitions;
22
22
  var CenterModal = forwardRef(function (props, ref) {
23
23
  var _a;
24
- var dataTestId = props.dataTestId, className = props.className, open = props.open, children = props.children, _b = props.width, width = _b === void 0 ? 500 : _b, _c = props.height, height = _c === void 0 ? 'hugContent' : _c, _d = props.verticalAlign, verticalAlign = _d === void 0 ? 'center' : _d, _e = props.overlay, overlay = _e === void 0 ? true : _e, margin = props.margin, scrollableContainerRefProp = props.scrollableContainerRef, onClose = props.onClose, restProps = __rest(props, ["dataTestId", "className", "open", "children", "width", "height", "verticalAlign", "overlay", "margin", "scrollableContainerRef", "onClose"]);
24
+ var dataTestId = props.dataTestId, className = props.className, open = props.open, children = props.children, _b = props.width, width = _b === void 0 ? 500 : _b, _c = props.height, height = _c === void 0 ? 'hugContent' : _c, _d = props.verticalAlign, verticalAlign = _d === void 0 ? 'center' : _d, _e = props.overlay, overlay = _e === void 0 ? true : _e, margin = props.margin, scrollableContainerRefProp = props.scrollableContainerRef, onClose = props.onClose, wrapperClassName = props.wrapperClassName, restProps = __rest(props, ["dataTestId", "className", "open", "children", "width", "height", "verticalAlign", "overlay", "margin", "scrollableContainerRef", "onClose", "wrapperClassName"]);
25
25
  var componentRef = useRef(null);
26
26
  var _f = useScrollableContainerRef({
27
27
  overlay: overlay,
@@ -29,7 +29,7 @@ var CenterModal = forwardRef(function (props, ref) {
29
29
  }), handleWheel = _f.handleWheel, scrollableContainerRef = _f.scrollableContainerRef;
30
30
  var _g = getFullSizeModalTransitions({ verticalAlign: verticalAlign, width: width, height: height }), isFullSizeModal = _g.isFullSizeModal, fullSizeModalContentTransitions = _g.componentTransitions, fullSizeModalBackdropTransitions = _g.backdropTransitions;
31
31
  var withoutOverlay = !overlay;
32
- return (React.createElement(BaseModal, __assign({}, restProps, { open: open, dataTestId: dataTestId, ref: ref, componentRef: componentRef, scrollHandler: 'content', disableBlockingScroll: withoutOverlay, wrapperClassName: cn(styles.baseModalContainer, (_a = {},
32
+ return (React.createElement(BaseModal, __assign({}, restProps, { open: open, dataTestId: dataTestId, ref: ref, componentRef: componentRef, scrollHandler: scrollableContainerRef, scrollContainerFillsViewport: false, disableBlockingScroll: withoutOverlay, wrapperClassName: cn(styles.baseModalContainer, wrapperClassName, (_a = {},
33
33
  _a[styles.wrapperJustifyStart] = verticalAlign === 'top',
34
34
  _a[styles.wrapperJustifyCenter] = verticalAlign === 'center',
35
35
  _a[styles.wrapperJustifyEnd] = verticalAlign === 'bottom',
@@ -1 +1 @@
1
- {"version":3,"file":"center-modal.js","sources":["../../../../src/desktop/components/center-modal/center-modal.tsx"],"sourcesContent":["import React, { forwardRef, useRef } from 'react';\nimport cn from 'classnames';\n\nimport { BaseModal } from '@alfalab/core-components-base-modal';\nimport { isMacOS, isSafari } from '@alfalab/core-components-shared';\n\nimport { useScrollableContainerRef } from '../../hooks/use-scrollable-container-ref';\nimport { type UniversalModalDesktopProps } from '../../types/props';\nimport { getFullSizeModalTransitions } from '../../utils/get-full-size-modal-transitions';\nimport { getHeightCapStyles } from '../../utils/get-height-cap-styles';\nimport { getHeightValue } from '../../utils/get-height-value';\nimport { getMarginStyles } from '../../utils/get-margin-styles';\nimport { getWidthCapStyles } from '../../utils/get-width-cap-styles';\nimport { ModalContent } from '../modal-content/modal-content';\n\nimport styles from './index.module.css';\nimport safariTransitions from './transitions/safari-transitions.module.css';\nimport transitions from './transitions/transitions.module.css';\n\n/*\n * в safari position:sticky некорректно синхронизируется с transform:scale на предке —\n * sticky-футер \"доезжает\" при анимации, поэтому применяем немного другую анимацию\n */\nconst transitionProps = isMacOS() && isSafari() ? safariTransitions : transitions;\n\nexport const CenterModal = forwardRef<HTMLDivElement, UniversalModalDesktopProps>((props, ref) => {\n const {\n dataTestId,\n className,\n open,\n children,\n width = 500,\n height = 'hugContent',\n verticalAlign = 'center',\n overlay = true,\n margin,\n scrollableContainerRef: scrollableContainerRefProp,\n onClose,\n ...restProps\n } = props;\n\n const componentRef = useRef<HTMLDivElement>(null);\n const { handleWheel, scrollableContainerRef } = useScrollableContainerRef({\n overlay,\n refObject: scrollableContainerRefProp,\n });\n\n const {\n isFullSizeModal,\n componentTransitions: fullSizeModalContentTransitions,\n backdropTransitions: fullSizeModalBackdropTransitions,\n } = getFullSizeModalTransitions({ verticalAlign, width, height });\n\n const withoutOverlay = !overlay;\n\n return (\n <BaseModal\n {...restProps}\n open={open}\n dataTestId={dataTestId}\n ref={ref}\n componentRef={componentRef}\n scrollHandler='content'\n disableBlockingScroll={withoutOverlay}\n wrapperClassName={cn(styles.baseModalContainer, {\n [styles.wrapperJustifyStart]: verticalAlign === 'top',\n [styles.wrapperJustifyCenter]: verticalAlign === 'center',\n [styles.wrapperJustifyEnd]: verticalAlign === 'bottom',\n [styles.withoutOverlay]: withoutOverlay,\n })}\n className={cn(\n styles.component,\n className,\n styles.baseModalComponent,\n getMarginStyles({ styles, margin }),\n getHeightCapStyles({ styles, margin }),\n getWidthCapStyles({ styles, margin }),\n )}\n transitionProps={{\n classNames: transitionProps,\n ...(isFullSizeModal && fullSizeModalContentTransitions),\n ...restProps.transitionProps,\n }}\n backdropProps={{\n shouldRender: overlay,\n ...(isFullSizeModal && fullSizeModalBackdropTransitions),\n ...restProps.backdropProps,\n }}\n componentDivProps={{\n style: {\n width: width === 'fullWidth' ? '100%' : width,\n height: getHeightValue(height),\n },\n }}\n onWheel={handleWheel}\n onClose={onClose}\n >\n <ModalContent height={height} scrollableContainerRef={scrollableContainerRef}>\n {children}\n </ModalContent>\n </BaseModal>\n );\n});\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAmBA;;;AAGG;AACH,IAAM,eAAe,GAAG,OAAO,EAAE,IAAI,QAAQ,EAAE,GAAG,iBAAiB,GAAG,WAAW;IAEpE,WAAW,GAAG,UAAU,CAA6C,UAAC,KAAK,EAAE,GAAG,EAAA;;AAErF,IAAA,IAAA,UAAU,GAYV,KAAK,CAZK,UAAA,EACV,SAAS,GAWT,KAAK,CAXI,SAAA,EACT,IAAI,GAUJ,KAAK,CAVD,IAAA,EACJ,QAAQ,GASR,KAAK,CATG,QAAA,EACR,KAQA,KAAK,CAAA,KARM,EAAX,KAAK,mBAAG,GAAG,GAAA,EAAA,EACX,EAAA,GAOA,KAAK,CAPgB,MAAA,EAArB,MAAM,GAAA,EAAA,KAAA,MAAA,GAAG,YAAY,GAAA,EAAA,EACrB,EAMA,GAAA,KAAK,cANmB,EAAxB,aAAa,GAAG,EAAA,KAAA,MAAA,GAAA,QAAQ,KAAA,EACxB,EAAA,GAKA,KAAK,CAAA,OALS,EAAd,OAAO,GAAA,EAAA,KAAA,MAAA,GAAG,IAAI,GAAA,EAAA,EACd,MAAM,GAIN,KAAK,CAAA,MAJC,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AACzD,YAAA,EAAA,CAAC,MAAM,CAAC,iBAAiB,CAAG,GAAA,aAAa,KAAK,QAAQ;AACtD,YAAA,EAAA,CAAC,MAAM,CAAC,cAAc,CAAA,GAAG,cAAc;AACzC,YAAA,EAAA,EAAA,EACF,SAAS,EAAE,EAAE,CACT,MAAM,CAAC,SAAS,EAChB,SAAS,EACT,MAAM,CAAC,kBAAkB,EACzB,eAAe,CAAC,EAAE,MAAM,EAAA,MAAA,EAAE,MAAM,QAAA,EAAE,CAAC,EACnC,kBAAkB,CAAC,EAAE,MAAM,EAAA,MAAA,EAAE,MAAM,EAAA,MAAA,EAAE,CAAC,EACtC,iBAAiB,CAAC,EAAE,MAAM,EAAA,MAAA,EAAE,MAAM,EAAA,MAAA,EAAE,CAAC,CACxC,EACD,eAAe,EAAA,QAAA,CAAA,QAAA,CAAA,EACX,UAAU,EAAE,eAAe,EACxB,GAAC,eAAe,IAAI,+BAA+B,EACnD,EAAA,SAAS,CAAC,eAAe,GAEhC,aAAa,EAAA,QAAA,CAAA,QAAA,CAAA,EACT,YAAY,EAAE,OAAO,KACjB,eAAe,IAAI,gCAAgC,EACpD,EAAA,SAAS,CAAC,aAAa,CAAA,EAE9B,iBAAiB,EAAE;AACf,YAAA,KAAK,EAAE;gBACH,KAAK,EAAE,KAAK,KAAK,WAAW,GAAG,MAAM,GAAG,KAAK;AAC7C,gBAAA,MAAM,EAAE,cAAc,CAAC,MAAM,CAAC;AACjC,aAAA;AACJ,SAAA,EACD,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,OAAO,EAAA,CAAA;AAEhB,QAAA,KAAA,CAAA,aAAA,CAAC,YAAY,EAAA,EAAC,MAAM,EAAE,MAAM,EAAE,sBAAsB,EAAE,sBAAsB,EACvE,EAAA,QAAQ,CACE,CACP;AAEpB,CAAC;;;;"}
1
+ {"version":3,"file":"center-modal.js","sources":["../../../../src/desktop/components/center-modal/center-modal.tsx"],"sourcesContent":["import React, { forwardRef, type MutableRefObject, useRef } from 'react';\nimport cn from 'classnames';\n\nimport { BaseModal } from '@alfalab/core-components-base-modal';\nimport { isMacOS, isSafari } from '@alfalab/core-components-shared';\n\nimport { useScrollableContainerRef } from '../../hooks/use-scrollable-container-ref';\nimport { type UniversalModalDesktopProps } from '../../types/props';\nimport { getFullSizeModalTransitions } from '../../utils/get-full-size-modal-transitions';\nimport { getHeightCapStyles } from '../../utils/get-height-cap-styles';\nimport { getHeightValue } from '../../utils/get-height-value';\nimport { getMarginStyles } from '../../utils/get-margin-styles';\nimport { getWidthCapStyles } from '../../utils/get-width-cap-styles';\nimport { ModalContent } from '../modal-content/modal-content';\n\nimport styles from './index.module.css';\nimport safariTransitions from './transitions/safari-transitions.module.css';\nimport transitions from './transitions/transitions.module.css';\n\n/*\n * в safari position:sticky некорректно синхронизируется с transform:scale на предке —\n * sticky-футер \"доезжает\" при анимации, поэтому применяем немного другую анимацию\n */\nconst transitionProps = isMacOS() && isSafari() ? safariTransitions : transitions;\n\nexport const CenterModal = forwardRef<HTMLDivElement, UniversalModalDesktopProps>((props, ref) => {\n const {\n dataTestId,\n className,\n open,\n children,\n width = 500,\n height = 'hugContent',\n verticalAlign = 'center',\n overlay = true,\n margin,\n scrollableContainerRef: scrollableContainerRefProp,\n onClose,\n wrapperClassName,\n ...restProps\n } = props;\n\n const componentRef = useRef<HTMLDivElement>(null);\n const { handleWheel, scrollableContainerRef } = useScrollableContainerRef({\n overlay,\n refObject: scrollableContainerRefProp,\n });\n\n const {\n isFullSizeModal,\n componentTransitions: fullSizeModalContentTransitions,\n backdropTransitions: fullSizeModalBackdropTransitions,\n } = getFullSizeModalTransitions({ verticalAlign, width, height });\n\n const withoutOverlay = !overlay;\n\n return (\n <BaseModal\n {...restProps}\n open={open}\n dataTestId={dataTestId}\n ref={ref}\n componentRef={componentRef}\n scrollHandler={scrollableContainerRef as MutableRefObject<HTMLDivElement | null>}\n scrollContainerFillsViewport={false}\n disableBlockingScroll={withoutOverlay}\n wrapperClassName={cn(styles.baseModalContainer, wrapperClassName, {\n [styles.wrapperJustifyStart]: verticalAlign === 'top',\n [styles.wrapperJustifyCenter]: verticalAlign === 'center',\n [styles.wrapperJustifyEnd]: verticalAlign === 'bottom',\n [styles.withoutOverlay]: withoutOverlay,\n })}\n className={cn(\n styles.component,\n className,\n styles.baseModalComponent,\n getMarginStyles({ styles, margin }),\n getHeightCapStyles({ styles, margin }),\n getWidthCapStyles({ styles, margin }),\n )}\n transitionProps={{\n classNames: transitionProps,\n ...(isFullSizeModal && fullSizeModalContentTransitions),\n ...restProps.transitionProps,\n }}\n backdropProps={{\n shouldRender: overlay,\n ...(isFullSizeModal && fullSizeModalBackdropTransitions),\n ...restProps.backdropProps,\n }}\n componentDivProps={{\n style: {\n width: width === 'fullWidth' ? '100%' : width,\n height: getHeightValue(height),\n },\n }}\n onWheel={handleWheel}\n onClose={onClose}\n >\n <ModalContent height={height} scrollableContainerRef={scrollableContainerRef}>\n {children}\n </ModalContent>\n </BaseModal>\n );\n});\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAmBA;;;AAGG;AACH,IAAM,eAAe,GAAG,OAAO,EAAE,IAAI,QAAQ,EAAE,GAAG,iBAAiB,GAAG,WAAW;IAEpE,WAAW,GAAG,UAAU,CAA6C,UAAC,KAAK,EAAE,GAAG,EAAA;;AAErF,IAAA,IAAA,UAAU,GAaV,KAAK,CAbK,UAAA,EACV,SAAS,GAYT,KAAK,CAZI,SAAA,EACT,IAAI,GAWJ,KAAK,KAXD,EACJ,QAAQ,GAUR,KAAK,CAAA,QAVG,EACR,EAAA,GASA,KAAK,CATM,KAAA,EAAX,KAAK,GAAG,EAAA,KAAA,MAAA,GAAA,GAAG,KAAA,EACX,EAAA,GAQA,KAAK,CAAA,MARgB,EAArB,MAAM,GAAA,EAAA,KAAA,MAAA,GAAG,YAAY,GAAA,EAAA,EACrB,KAOA,KAAK,CAAA,aAPmB,EAAxB,aAAa,mBAAG,QAAQ,GAAA,EAAA,EACxB,EAAA,GAMA,KAAK,CAN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