@alfalab/core-components-bottom-sheet 8.0.1 → 8.0.2

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 (66) hide show
  1. package/components/footer/default.css +2 -2
  2. package/components/footer/default.module.css.js +1 -1
  3. package/components/footer/index.css +2 -2
  4. package/components/footer/index.module.css.js +1 -1
  5. package/components/footer/inverted.css +2 -2
  6. package/components/footer/inverted.module.css.js +1 -1
  7. package/components/header/Component.js +3 -3
  8. package/components/header/Component.js.map +1 -1
  9. package/components/header/default.css +4 -4
  10. package/components/header/default.module.css.js +1 -1
  11. package/components/header/index.css +13 -13
  12. package/components/header/index.module.css.js +1 -1
  13. package/components/header/inverted.css +4 -4
  14. package/components/header/inverted.module.css.js +1 -1
  15. package/cssm/components/header/Component.js +3 -3
  16. package/cssm/components/header/Component.js.map +1 -1
  17. package/default.css +4 -4
  18. package/default.module.css.js +1 -1
  19. package/esm/components/footer/default.css +2 -2
  20. package/esm/components/footer/default.module.css.js +1 -1
  21. package/esm/components/footer/index.css +2 -2
  22. package/esm/components/footer/index.module.css.js +1 -1
  23. package/esm/components/footer/inverted.css +2 -2
  24. package/esm/components/footer/inverted.module.css.js +1 -1
  25. package/esm/components/header/Component.js +3 -3
  26. package/esm/components/header/Component.js.map +1 -1
  27. package/esm/components/header/default.css +4 -4
  28. package/esm/components/header/default.module.css.js +1 -1
  29. package/esm/components/header/index.css +13 -13
  30. package/esm/components/header/index.module.css.js +1 -1
  31. package/esm/components/header/inverted.css +4 -4
  32. package/esm/components/header/inverted.module.css.js +1 -1
  33. package/esm/default.css +4 -4
  34. package/esm/default.module.css.js +1 -1
  35. package/esm/index.css +45 -45
  36. package/esm/index.module.css.js +1 -1
  37. package/esm/inverted.css +4 -4
  38. package/esm/inverted.module.css.js +1 -1
  39. package/index.css +45 -45
  40. package/index.module.css.js +1 -1
  41. package/inverted.css +4 -4
  42. package/inverted.module.css.js +1 -1
  43. package/modern/components/footer/default.css +2 -2
  44. package/modern/components/footer/default.module.css.js +1 -1
  45. package/modern/components/footer/index.css +2 -2
  46. package/modern/components/footer/index.module.css.js +1 -1
  47. package/modern/components/footer/inverted.css +2 -2
  48. package/modern/components/footer/inverted.module.css.js +1 -1
  49. package/modern/components/header/Component.js +3 -3
  50. package/modern/components/header/Component.js.map +1 -1
  51. package/modern/components/header/default.css +4 -4
  52. package/modern/components/header/default.module.css.js +1 -1
  53. package/modern/components/header/index.css +13 -13
  54. package/modern/components/header/index.module.css.js +1 -1
  55. package/modern/components/header/inverted.css +4 -4
  56. package/modern/components/header/inverted.module.css.js +1 -1
  57. package/modern/default.css +4 -4
  58. package/modern/default.module.css.js +1 -1
  59. package/modern/index.css +45 -45
  60. package/modern/index.module.css.js +1 -1
  61. package/modern/inverted.css +4 -4
  62. package/modern/inverted.module.css.js +1 -1
  63. package/moderncssm/components/header/Component.js +3 -3
  64. package/moderncssm/components/header/Component.js.map +1 -1
  65. package/package.json +1 -1
  66. package/src/components/header/Component.tsx +3 -1
@@ -1 +1 @@
1
- {"version":3,"file":"Component.js","sources":["../../../src/components/header/Component.tsx"],"sourcesContent":["import React, { type FC, type RefObject, useContext, useEffect } from 'react';\nimport cn from 'classnames';\n\nimport { BaseModalContext } from '@alfalab/core-components-base-modal';\nimport {\n NavigationBarPrivate,\n type NavigationBarPrivateProps,\n} from '@alfalab/core-components-navigation-bar-private';\n\nimport { type ColorType } from '../../types';\n\nimport defaultColors from './default.module.css';\nimport styles from './index.module.css';\nimport invertedColors from './inverted.module.css';\n\nexport type HeaderProps = Omit<NavigationBarPrivateProps, 'view' | 'size'> & {\n headerRef: RefObject<HTMLDivElement>;\n headerOffset: number;\n colors?: ColorType;\n showSwipeMarker?: boolean;\n};\n\nconst colorStyles = {\n default: defaultColors,\n inverted: invertedColors,\n} as const;\n\nexport const Header: FC<HeaderProps> = ({\n className,\n colors = 'default',\n sticky,\n headerRef,\n headerOffset,\n showSwipeMarker,\n title,\n children,\n contentClassName,\n ...restProps\n}) => {\n const { setHeaderOffset, setHasHeader, headerHighlighted, onClose } =\n useContext(BaseModalContext);\n\n useEffect(() => {\n setHeaderOffset(headerOffset);\n }, [headerOffset, setHeaderOffset]);\n\n useEffect(() => {\n setHasHeader(true);\n }, [setHasHeader]);\n\n const colorStyle = colorStyles[colors];\n const hasContent = Boolean(title || children);\n\n return (\n <NavigationBarPrivate\n {...restProps}\n ref={headerRef}\n title={title}\n onClose={onClose}\n sticky={sticky}\n view='mobile'\n className={cn(className, {\n [styles.headerWrapper]: showSwipeMarker,\n [styles.headerWrapperWithoutSwipeMarker]: !showSwipeMarker,\n [colorStyle.highlighted]: hasContent && headerHighlighted && sticky,\n [colorStyle.hasContent]: hasContent,\n [styles.sticky]: sticky,\n })}\n contentClassName={cn(styles.title, contentClassName)}\n titleClassName={cn(colorStyle.title)}\n subtitleClassName={cn(styles.subtitle, colorStyle.subtitle)}\n colors={colors}\n >\n {children}\n </NavigationBarPrivate>\n );\n};\n"],"names":[],"mappings":";;;;;;;;AAsBA,MAAM,WAAW,GAAG;AAChB,IAAA,OAAO,EAAE,aAAa;AACtB,IAAA,QAAQ,EAAE,cAAc;CAClB;AAEH,MAAM,MAAM,GAAoB,CAAC,EACpC,SAAS,EACT,MAAM,GAAG,SAAS,EAClB,MAAM,EACN,SAAS,EACT,YAAY,EACZ,eAAe,EACf,KAAK,EACL,QAAQ,EACR,gBAAgB,EAChB,GAAG,SAAS,EACf,KAAI;AACD,IAAA,MAAM,EAAE,eAAe,EAAE,YAAY,EAAE,iBAAiB,EAAE,OAAO,EAAE,GAC/D,UAAU,CAAC,gBAAgB,CAAC;IAEhC,SAAS,CAAC,MAAK;QACX,eAAe,CAAC,YAAY,CAAC;AACjC,KAAC,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC,CAAC;IAEnC,SAAS,CAAC,MAAK;QACX,YAAY,CAAC,IAAI,CAAC;AACtB,KAAC,EAAE,CAAC,YAAY,CAAC,CAAC;AAElB,IAAA,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,CAAC;IACtC,MAAM,UAAU,GAAG,OAAO,CAAC,KAAK,IAAI,QAAQ,CAAC;AAE7C,IAAA,QACI,KAAA,CAAA,aAAA,CAAC,oBAAoB,EAAA,EAAA,GACb,SAAS,EACb,GAAG,EAAE,SAAS,EACd,KAAK,EAAE,KAAK,EACZ,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,EACd,IAAI,EAAC,QAAQ,EACb,SAAS,EAAE,EAAE,CAAC,SAAS,EAAE;AACrB,YAAA,CAAC,MAAM,CAAC,aAAa,GAAG,eAAe;AACvC,YAAA,CAAC,MAAM,CAAC,+BAA+B,GAAG,CAAC,eAAe;YAC1D,CAAC,UAAU,CAAC,WAAW,GAAG,UAAU,IAAI,iBAAiB,IAAI,MAAM;AACnE,YAAA,CAAC,UAAU,CAAC,UAAU,GAAG,UAAU;AACnC,YAAA,CAAC,MAAM,CAAC,MAAM,GAAG,MAAM;AAC1B,SAAA,CAAC,EACF,gBAAgB,EAAE,EAAE,CAAC,MAAM,CAAC,KAAK,EAAE,gBAAgB,CAAC,EACpD,cAAc,EAAE,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,EACpC,iBAAiB,EAAE,EAAE,CAAC,MAAM,CAAC,QAAQ,EAAE,UAAU,CAAC,QAAQ,CAAC,EAC3D,MAAM,EAAE,MAAM,IAEb,QAAQ,CACU;AAE/B;;;;"}
1
+ {"version":3,"file":"Component.js","sources":["../../../src/components/header/Component.tsx"],"sourcesContent":["import React, { type FC, type RefObject, useContext, useEffect } from 'react';\nimport cn from 'classnames';\n\nimport { BaseModalContext } from '@alfalab/core-components-base-modal';\nimport {\n NavigationBarPrivate,\n type NavigationBarPrivateProps,\n} from '@alfalab/core-components-navigation-bar-private';\n\nimport { type ColorType } from '../../types';\n\nimport defaultColors from './default.module.css';\nimport styles from './index.module.css';\nimport invertedColors from './inverted.module.css';\n\nexport type HeaderProps = Omit<NavigationBarPrivateProps, 'view' | 'size'> & {\n headerRef: RefObject<HTMLDivElement>;\n headerOffset: number;\n colors?: ColorType;\n showSwipeMarker?: boolean;\n};\n\nconst colorStyles = {\n default: defaultColors,\n inverted: invertedColors,\n} as const;\n\nexport const Header: FC<HeaderProps> = ({\n className,\n colors = 'default',\n sticky,\n headerRef,\n headerOffset,\n showSwipeMarker,\n title,\n children,\n contentClassName,\n bottomAddons,\n ...restProps\n}) => {\n const { setHeaderOffset, setHasHeader, headerHighlighted, onClose } =\n useContext(BaseModalContext);\n\n useEffect(() => {\n setHeaderOffset(headerOffset);\n }, [headerOffset, setHeaderOffset]);\n\n useEffect(() => {\n setHasHeader(true);\n }, [setHasHeader]);\n\n const colorStyle = colorStyles[colors];\n const hasContent = Boolean(title || children || bottomAddons);\n\n return (\n <NavigationBarPrivate\n {...restProps}\n ref={headerRef}\n title={title}\n bottomAddons={bottomAddons}\n onClose={onClose}\n sticky={sticky}\n view='mobile'\n className={cn(className, {\n [styles.headerWrapper]: showSwipeMarker,\n [styles.headerWrapperWithoutSwipeMarker]: !showSwipeMarker,\n [colorStyle.highlighted]: hasContent && headerHighlighted && sticky,\n [colorStyle.hasContent]: hasContent,\n [styles.sticky]: sticky,\n })}\n contentClassName={cn(styles.title, contentClassName)}\n titleClassName={cn(colorStyle.title)}\n subtitleClassName={cn(styles.subtitle, colorStyle.subtitle)}\n colors={colors}\n >\n {children}\n </NavigationBarPrivate>\n );\n};\n"],"names":[],"mappings":";;;;;;;;AAsBA,MAAM,WAAW,GAAG;AAChB,IAAA,OAAO,EAAE,aAAa;AACtB,IAAA,QAAQ,EAAE,cAAc;CAClB;AAEH,MAAM,MAAM,GAAoB,CAAC,EACpC,SAAS,EACT,MAAM,GAAG,SAAS,EAClB,MAAM,EACN,SAAS,EACT,YAAY,EACZ,eAAe,EACf,KAAK,EACL,QAAQ,EACR,gBAAgB,EAChB,YAAY,EACZ,GAAG,SAAS,EACf,KAAI;AACD,IAAA,MAAM,EAAE,eAAe,EAAE,YAAY,EAAE,iBAAiB,EAAE,OAAO,EAAE,GAC/D,UAAU,CAAC,gBAAgB,CAAC;IAEhC,SAAS,CAAC,MAAK;QACX,eAAe,CAAC,YAAY,CAAC;AACjC,KAAC,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC,CAAC;IAEnC,SAAS,CAAC,MAAK;QACX,YAAY,CAAC,IAAI,CAAC;AACtB,KAAC,EAAE,CAAC,YAAY,CAAC,CAAC;AAElB,IAAA,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,CAAC;IACtC,MAAM,UAAU,GAAG,OAAO,CAAC,KAAK,IAAI,QAAQ,IAAI,YAAY,CAAC;AAE7D,IAAA,QACI,KAAA,CAAA,aAAA,CAAC,oBAAoB,EAAA,EAAA,GACb,SAAS,EACb,GAAG,EAAE,SAAS,EACd,KAAK,EAAE,KAAK,EACZ,YAAY,EAAE,YAAY,EAC1B,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,EACd,IAAI,EAAC,QAAQ,EACb,SAAS,EAAE,EAAE,CAAC,SAAS,EAAE;AACrB,YAAA,CAAC,MAAM,CAAC,aAAa,GAAG,eAAe;AACvC,YAAA,CAAC,MAAM,CAAC,+BAA+B,GAAG,CAAC,eAAe;YAC1D,CAAC,UAAU,CAAC,WAAW,GAAG,UAAU,IAAI,iBAAiB,IAAI,MAAM;AACnE,YAAA,CAAC,UAAU,CAAC,UAAU,GAAG,UAAU;AACnC,YAAA,CAAC,MAAM,CAAC,MAAM,GAAG,MAAM;AAC1B,SAAA,CAAC,EACF,gBAAgB,EAAE,EAAE,CAAC,MAAM,CAAC,KAAK,EAAE,gBAAgB,CAAC,EACpD,cAAc,EAAE,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,EACpC,iBAAiB,EAAE,EAAE,CAAC,MAAM,CAAC,QAAQ,EAAE,UAAU,CAAC,QAAQ,CAAC,EAC3D,MAAM,EAAE,MAAM,IAEb,QAAQ,CACU;AAE/B;;;;"}
@@ -6,15 +6,15 @@
6
6
  --bottom-sheet-header-border-bottom: 1px solid var(--color-light-neutral-300);
7
7
  --bottom-sheet-text-color: var(--color-light-text-primary);
8
8
  }
9
- .bottom-sheet__title_1tf2d {
9
+ .bottom-sheet__title_1ucm9 {
10
10
  color: var(--bottom-sheet-text-color);
11
11
  }
12
- .bottom-sheet__hasContent_1tf2d {
12
+ .bottom-sheet__hasContent_1ucm9 {
13
13
  background-color: inherit;
14
14
  }
15
- .bottom-sheet__subtitle_1tf2d.bottom-sheet__subtitle_1tf2d {
15
+ .bottom-sheet__subtitle_1ucm9.bottom-sheet__subtitle_1ucm9 {
16
16
  color: var(--bottom-sheet-text-color);
17
17
  }
18
- .bottom-sheet__highlighted_1tf2d {
18
+ .bottom-sheet__highlighted_1ucm9 {
19
19
  border-bottom: var(--bottom-sheet-header-border-bottom);
20
20
  }
@@ -1,6 +1,6 @@
1
1
  import './default.css';
2
2
 
3
- const defaultColors = {"title":"bottom-sheet__title_1tf2d","hasContent":"bottom-sheet__hasContent_1tf2d","subtitle":"bottom-sheet__subtitle_1tf2d","highlighted":"bottom-sheet__highlighted_1tf2d"};
3
+ const defaultColors = {"title":"bottom-sheet__title_1ucm9","hasContent":"bottom-sheet__hasContent_1ucm9","subtitle":"bottom-sheet__subtitle_1ucm9","highlighted":"bottom-sheet__highlighted_1ucm9"};
4
4
 
5
5
  export { defaultColors as default };
6
6
  //# sourceMappingURL=default.module.css.js.map
@@ -12,38 +12,38 @@
12
12
  --font-family-system:
13
13
  system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Helvetica, sans-serif;
14
14
  }
15
- .bottom-sheet__headerBase_3v98l {
15
+ .bottom-sheet__headerBase_nzj4a {
16
16
  border-top-left-radius: inherit;
17
17
  border-top-right-radius: inherit;
18
18
  z-index: 1;
19
19
  }
20
- .bottom-sheet__headerWrapper_3v98l {
20
+ .bottom-sheet__headerWrapper_nzj4a {
21
21
  padding: var(--gap-12) var(--gap-8) var(--gap-4);
22
22
  }
23
- .bottom-sheet__headerWrapperWithoutSwipeMarker_3v98l {
23
+ .bottom-sheet__headerWrapperWithoutSwipeMarker_nzj4a {
24
24
  padding: var(--gap-8) var(--gap-8) var(--gap-4);
25
25
  }
26
- .bottom-sheet__header_3v98l {
26
+ .bottom-sheet__header_nzj4a {
27
27
  display: flex;
28
28
  }
29
- .bottom-sheet__sticky_3v98l {
29
+ .bottom-sheet__sticky_nzj4a {
30
30
  position: sticky;
31
31
  top: var(--gap-0);
32
32
  }
33
- .bottom-sheet__justifyEnd_3v98l {
33
+ .bottom-sheet__justifyEnd_nzj4a {
34
34
  justify-content: flex-end;
35
35
  }
36
- .bottom-sheet__addon_3v98l {
36
+ .bottom-sheet__addon_nzj4a {
37
37
  display: flex;
38
38
  justify-content: center;
39
39
  align-items: center;
40
40
  min-width: 48px;
41
41
  height: 48px;
42
42
  }
43
- .bottom-sheet__addonFixed_3v98l {
43
+ .bottom-sheet__addonFixed_nzj4a {
44
44
  position: fixed;
45
45
  }
46
- .bottom-sheet__title_3v98l {
46
+ .bottom-sheet__title_nzj4a {
47
47
  padding: var(--gap-10) var(--gap-8);
48
48
  width: 100%;
49
49
 
@@ -55,18 +55,18 @@
55
55
 
56
56
  font-family: var(--font-family-system);
57
57
  }
58
- .bottom-sheet__titleCenter_3v98l {
58
+ .bottom-sheet__titleCenter_nzj4a {
59
59
  text-align: center;
60
60
  }
61
- .bottom-sheet__titleLeft_3v98l {
61
+ .bottom-sheet__titleLeft_nzj4a {
62
62
  text-align: left;
63
63
  }
64
- .bottom-sheet__trimTitle_3v98l {
64
+ .bottom-sheet__trimTitle_nzj4a {
65
65
  white-space: nowrap;
66
66
  overflow: hidden;
67
67
  text-overflow: ellipsis;
68
68
  }
69
- .bottom-sheet__subtitle_3v98l {
69
+ .bottom-sheet__subtitle_nzj4a {
70
70
  width: 100%;
71
71
 
72
72
  font-size: 14px;
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- const styles = {"headerWrapper":"bottom-sheet__headerWrapper_3v98l bottom-sheet__headerBase_3v98l","headerWrapperWithoutSwipeMarker":"bottom-sheet__headerWrapperWithoutSwipeMarker_3v98l bottom-sheet__headerBase_3v98l","sticky":"bottom-sheet__sticky_3v98l","title":"bottom-sheet__title_3v98l","subtitle":"bottom-sheet__subtitle_3v98l"};
3
+ const styles = {"headerWrapper":"bottom-sheet__headerWrapper_nzj4a bottom-sheet__headerBase_nzj4a","headerWrapperWithoutSwipeMarker":"bottom-sheet__headerWrapperWithoutSwipeMarker_nzj4a bottom-sheet__headerBase_nzj4a","sticky":"bottom-sheet__sticky_nzj4a","title":"bottom-sheet__title_nzj4a","subtitle":"bottom-sheet__subtitle_nzj4a"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -6,15 +6,15 @@
6
6
  --bottom-sheet-header-border-bottom-inverted: 1px solid var(--color-light-neutral-300-inverted);
7
7
  --bottom-sheet-text-color-inverted: var(--color-light-text-primary-inverted);
8
8
  }
9
- .bottom-sheet__title_n4jp3 {
9
+ .bottom-sheet__title_o23la {
10
10
  color: var(--bottom-sheet-text-color-inverted);
11
11
  }
12
- .bottom-sheet__hasContent_n4jp3 {
12
+ .bottom-sheet__hasContent_o23la {
13
13
  background-color: inherit;
14
14
  }
15
- .bottom-sheet__subtitle_n4jp3.bottom-sheet__subtitle_n4jp3 {
15
+ .bottom-sheet__subtitle_o23la.bottom-sheet__subtitle_o23la {
16
16
  color: var(--bottom-sheet-text-color-inverted);
17
17
  }
18
- .bottom-sheet__highlighted_n4jp3 {
18
+ .bottom-sheet__highlighted_o23la {
19
19
  border-bottom: var(--bottom-sheet-header-border-bottom-inverted);
20
20
  }
@@ -1,6 +1,6 @@
1
1
  import './inverted.css';
2
2
 
3
- const invertedColors = {"title":"bottom-sheet__title_n4jp3","hasContent":"bottom-sheet__hasContent_n4jp3","subtitle":"bottom-sheet__subtitle_n4jp3","highlighted":"bottom-sheet__highlighted_n4jp3"};
3
+ const invertedColors = {"title":"bottom-sheet__title_o23la","hasContent":"bottom-sheet__hasContent_o23la","subtitle":"bottom-sheet__subtitle_o23la","highlighted":"bottom-sheet__highlighted_o23la"};
4
4
 
5
5
  export { invertedColors as default };
6
6
  //# sourceMappingURL=inverted.module.css.js.map
@@ -8,15 +8,15 @@
8
8
  --bottom-sheet-marker-color: var(--color-light-neutral-translucent-300);
9
9
  --bottom-sheet-text-color: var(--color-light-text-primary);
10
10
  }
11
- .bottom-sheet__component_1oyrw {
11
+ .bottom-sheet__component_25431 {
12
12
  background-color: var(--bottom-sheet-background-color);
13
13
  }
14
- .bottom-sheet__content_1oyrw {
14
+ .bottom-sheet__content_25431 {
15
15
  color: var(--bottom-sheet-text-color);
16
16
  }
17
- .bottom-sheet__defaultMarker_1oyrw {
17
+ .bottom-sheet__defaultMarker_25431 {
18
18
  background-color: var(--bottom-sheet-marker-color);
19
19
  }
20
- .bottom-sheet__hasContent_1oyrw {
20
+ .bottom-sheet__hasContent_25431 {
21
21
  color: var(--bottom-sheet-text-color);
22
22
  }
@@ -1,6 +1,6 @@
1
1
  import './default.css';
2
2
 
3
- const defaultColors = {"component":"bottom-sheet__component_1oyrw","content":"bottom-sheet__content_1oyrw","defaultMarker":"bottom-sheet__defaultMarker_1oyrw","hasContent":"bottom-sheet__hasContent_1oyrw"};
3
+ const defaultColors = {"component":"bottom-sheet__component_25431","content":"bottom-sheet__content_25431","defaultMarker":"bottom-sheet__defaultMarker_25431","hasContent":"bottom-sheet__hasContent_25431"};
4
4
 
5
5
  export { defaultColors as default };
6
6
  //# sourceMappingURL=default.module.css.js.map
package/modern/index.css CHANGED
@@ -45,18 +45,18 @@
45
45
  --bottom-sheet-top-radius: var(--border-radius-16);
46
46
  --bottom-sheet-shadow: none;
47
47
  }
48
- .bottom-sheet__modal_171py {
48
+ .bottom-sheet__modal_wku8l {
49
49
  bottom: var(--gap-0);
50
50
  width: 100%;
51
51
  max-width: 600px;
52
52
  pointer-events: none;
53
53
  touch-action: none;
54
54
  }
55
- .bottom-sheet__modal_171py.bottom-sheet__modal_171py {
55
+ .bottom-sheet__modal_wku8l.bottom-sheet__modal_wku8l {
56
56
  background-color: transparent;
57
57
  position: fixed;
58
58
  }
59
- .bottom-sheet__wrapper_171py {
59
+ .bottom-sheet__wrapper_wku8l {
60
60
  transform: translateY(100%);
61
61
  pointer-events: none;
62
62
  touch-action: none;
@@ -64,13 +64,13 @@
64
64
  border-top-left-radius: var(--bottom-sheet-top-radius);
65
65
  transition: border-radius 0.3s ease;
66
66
  }
67
- .bottom-sheet__outerClassName_171py {
67
+ .bottom-sheet__outerClassName_wku8l {
68
68
  pointer-events: all;
69
69
  }
70
- .bottom-sheet__fullscreen_171py {
70
+ .bottom-sheet__fullscreen_wku8l {
71
71
  border-radius: var(--border-radius-0);
72
72
  }
73
- .bottom-sheet__component_171py {
73
+ .bottom-sheet__component_wku8l {
74
74
  position: relative;
75
75
  display: flex;
76
76
  flex-direction: column;
@@ -79,10 +79,10 @@
79
79
  box-shadow: var(--bottom-sheet-shadow);
80
80
  transform: translate(0, 0);
81
81
  }
82
- .bottom-sheet__withTransition_171py {
82
+ .bottom-sheet__withTransition_wku8l {
83
83
  transition: var(--bottom-sheet-out-transition);
84
84
  }
85
- .bottom-sheet__scrollableContainer_171py {
85
+ .bottom-sheet__scrollableContainer_wku8l {
86
86
  overflow: auto;
87
87
  display: flex;
88
88
  flex-direction: column;
@@ -92,7 +92,7 @@
92
92
  border-radius: inherit;
93
93
  overscroll-behavior: contain;
94
94
  }
95
- .bottom-sheet__marker_171py {
95
+ .bottom-sheet__marker_wku8l {
96
96
  position: fixed;
97
97
  top: var(--gap-4);
98
98
  right: var(--gap-0);
@@ -101,11 +101,11 @@
101
101
  width: 36px;
102
102
  margin: var(--gap-0) auto;
103
103
  }
104
- .bottom-sheet__defaultMarker_171py {
104
+ .bottom-sheet__defaultMarker_wku8l {
105
105
  height: 4px;
106
106
  border-radius: var(--border-radius-20);
107
107
  }
108
- .bottom-sheet__content_171py {
108
+ .bottom-sheet__content_wku8l {
109
109
  position: relative;
110
110
  z-index: 0;
111
111
  display: flex;
@@ -115,108 +115,108 @@
115
115
  background-color: inherit;
116
116
  border-radius: inherit;
117
117
  }
118
- .bottom-sheet__noHeader_171py {
118
+ .bottom-sheet__noHeader_wku8l {
119
119
  padding-top: var(--gap-16);
120
120
  }
121
- .bottom-sheet__noFooter_171py {
121
+ .bottom-sheet__noFooter_wku8l {
122
122
  padding-bottom: var(--gap-16);
123
123
  }
124
- .bottom-sheet__scrollLocked_171py {
124
+ .bottom-sheet__scrollLocked_wku8l {
125
125
  overflow: hidden;
126
126
  }
127
- .bottom-sheet__hiddenScrollbar_171py {
127
+ .bottom-sheet__hiddenScrollbar_wku8l {
128
128
  scrollbar-width: none;
129
129
  }
130
- .bottom-sheet__hiddenScrollbar_171py::-webkit-scrollbar {
130
+ .bottom-sheet__hiddenScrollbar_wku8l::-webkit-scrollbar {
131
131
  width: 0;
132
132
  height: 0;
133
133
  }
134
- .bottom-sheet__disabledPointerEvents_171py {
134
+ .bottom-sheet__disabledPointerEvents_wku8l {
135
135
  pointer-events: none;
136
136
  }
137
- .bottom-sheet__appear_171py .bottom-sheet__wrapper_171py, .bottom-sheet__enter_171py .bottom-sheet__wrapper_171py {
137
+ .bottom-sheet__appear_wku8l .bottom-sheet__wrapper_wku8l, .bottom-sheet__enter_wku8l .bottom-sheet__wrapper_wku8l {
138
138
  transition: none;
139
139
  }
140
- .bottom-sheet__appearActive_171py .bottom-sheet__wrapper_171py, .bottom-sheet__enterActive_171py .bottom-sheet__wrapper_171py {
140
+ .bottom-sheet__appearActive_wku8l .bottom-sheet__wrapper_wku8l, .bottom-sheet__enterActive_wku8l .bottom-sheet__wrapper_wku8l {
141
141
  transition: var(--bottom-sheet-in-transition);
142
142
  transform: translateY(0);
143
143
  }
144
- .bottom-sheet__enterDone_171py .bottom-sheet__wrapper_171py, .bottom-sheet__appearDone_171py .bottom-sheet__wrapper_171py {
144
+ .bottom-sheet__enterDone_wku8l .bottom-sheet__wrapper_wku8l, .bottom-sheet__appearDone_wku8l .bottom-sheet__wrapper_wku8l {
145
145
  transform: translateY(0);
146
146
  }
147
- .bottom-sheet__exit_171py .bottom-sheet__wrapper_171py {
147
+ .bottom-sheet__exit_wku8l .bottom-sheet__wrapper_wku8l {
148
148
  transform: translateY(0);
149
149
  }
150
- .bottom-sheet__exitActive_171py .bottom-sheet__wrapper_171py {
150
+ .bottom-sheet__exitActive_wku8l .bottom-sheet__wrapper_wku8l {
151
151
  transition: var(--bottom-sheet-out-transition);
152
152
  transform: translateY(100%);
153
153
  }
154
- .bottom-sheet__safeAreaBottom_171py {
154
+ .bottom-sheet__safeAreaBottom_wku8l {
155
155
  padding-bottom: var(--sab);
156
156
  }
157
- .bottom-sheet__background-accent_171py {
157
+ .bottom-sheet__background-accent_wku8l {
158
158
  background-color: var(--color-light-bg-accent);
159
159
  }
160
- .bottom-sheet__background-info_171py {
160
+ .bottom-sheet__background-info_wku8l {
161
161
  background-color: var(--color-light-bg-info);
162
162
  }
163
- .bottom-sheet__background-attention-muted_171py {
163
+ .bottom-sheet__background-attention-muted_wku8l {
164
164
  background-color: var(--color-light-bg-attention-muted);
165
165
  }
166
- .bottom-sheet__background-positive-muted_171py {
166
+ .bottom-sheet__background-positive-muted_wku8l {
167
167
  background-color: var(--color-light-bg-positive-muted);
168
168
  }
169
- .bottom-sheet__background-negative-muted_171py {
169
+ .bottom-sheet__background-negative-muted_wku8l {
170
170
  background-color: var(--color-light-bg-negative-muted);
171
171
  }
172
- .bottom-sheet__background-primary_171py {
172
+ .bottom-sheet__background-primary_wku8l {
173
173
  background-color: var(--color-light-bg-primary);
174
174
  }
175
- .bottom-sheet__background-primary-inverted_171py {
175
+ .bottom-sheet__background-primary-inverted_wku8l {
176
176
  background-color: var(--color-light-bg-primary-inverted);
177
177
  }
178
- .bottom-sheet__background-secondary_171py {
178
+ .bottom-sheet__background-secondary_wku8l {
179
179
  background-color: var(--color-light-bg-secondary);
180
180
  }
181
- .bottom-sheet__background-secondary-inverted_171py {
181
+ .bottom-sheet__background-secondary-inverted_wku8l {
182
182
  background-color: var(--color-light-bg-secondary-inverted);
183
183
  }
184
- .bottom-sheet__background-tertiary_171py {
184
+ .bottom-sheet__background-tertiary_wku8l {
185
185
  background-color: var(--color-light-bg-tertiary);
186
186
  }
187
- .bottom-sheet__background-tertiary-inverted_171py {
187
+ .bottom-sheet__background-tertiary-inverted_wku8l {
188
188
  background-color: var(--color-light-bg-tertiary-inverted);
189
189
  }
190
- .bottom-sheet__background-quaternary_171py {
190
+ .bottom-sheet__background-quaternary_wku8l {
191
191
  background-color: var(--color-light-bg-quaternary);
192
192
  }
193
- .bottom-sheet__background-quaternary-inverted_171py {
193
+ .bottom-sheet__background-quaternary-inverted_wku8l {
194
194
  background-color: var(--color-light-bg-quaternary-inverted);
195
195
  }
196
- .bottom-sheet__background-specialbg-component_171py {
196
+ .bottom-sheet__background-specialbg-component_wku8l {
197
197
  background-color: var(--color-light-specialbg-component);
198
198
  }
199
- .bottom-sheet__background-specialbg-component-inverted_171py {
199
+ .bottom-sheet__background-specialbg-component-inverted_wku8l {
200
200
  background-color: var(--color-light-specialbg-component-inverted);
201
201
  }
202
- .bottom-sheet__background-specialbg-primary-grouped_171py {
202
+ .bottom-sheet__background-specialbg-primary-grouped_wku8l {
203
203
  background-color: var(--color-light-specialbg-primary-grouped);
204
204
  }
205
- .bottom-sheet__background-specialbg-secondary-grouped_171py {
205
+ .bottom-sheet__background-specialbg-secondary-grouped_wku8l {
206
206
  background-color: var(--color-light-specialbg-secondary-grouped);
207
207
  }
208
- .bottom-sheet__background-specialbg-tertiary-grouped_171py {
208
+ .bottom-sheet__background-specialbg-tertiary-grouped_wku8l {
209
209
  background-color: var(--color-light-specialbg-tertiary-grouped);
210
210
  }
211
- .bottom-sheet__background-specialbg-secondary-transparent_171py {
211
+ .bottom-sheet__background-specialbg-secondary-transparent_wku8l {
212
212
  background-color: var(--color-light-specialbg-secondary-transparent);
213
213
  }
214
- .bottom-sheet__background-specialbg-secondary-transparent-inverted_171py {
214
+ .bottom-sheet__background-specialbg-secondary-transparent-inverted_wku8l {
215
215
  background-color: var(--color-light-specialbg-secondary-transparent-inverted);
216
216
  }
217
- .bottom-sheet__background-specialbg-tertiary-transparent_171py {
217
+ .bottom-sheet__background-specialbg-tertiary-transparent_wku8l {
218
218
  background-color: var(--color-light-specialbg-tertiary-transparent);
219
219
  }
220
- .bottom-sheet__background-specialbg-tertiary-transparent-inverted_171py {
220
+ .bottom-sheet__background-specialbg-tertiary-transparent-inverted_wku8l {
221
221
  background-color: var(--color-light-specialbg-tertiary-transparent-inverted);
222
222
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- const styles = {"modal":"bottom-sheet__modal_171py","wrapper":"bottom-sheet__wrapper_171py","outerClassName":"bottom-sheet__outerClassName_171py","fullscreen":"bottom-sheet__fullscreen_171py","component":"bottom-sheet__component_171py","withTransition":"bottom-sheet__withTransition_171py","scrollableContainer":"bottom-sheet__scrollableContainer_171py","marker":"bottom-sheet__marker_171py","defaultMarker":"bottom-sheet__defaultMarker_171py","content":"bottom-sheet__content_171py","noHeader":"bottom-sheet__noHeader_171py","noFooter":"bottom-sheet__noFooter_171py","scrollLocked":"bottom-sheet__scrollLocked_171py","hiddenScrollbar":"bottom-sheet__hiddenScrollbar_171py","disabledPointerEvents":"bottom-sheet__disabledPointerEvents_171py","appear":"bottom-sheet__appear_171py","enter":"bottom-sheet__enter_171py","appearActive":"bottom-sheet__appearActive_171py","enterActive":"bottom-sheet__enterActive_171py","enterDone":"bottom-sheet__enterDone_171py","appearDone":"bottom-sheet__appearDone_171py","exit":"bottom-sheet__exit_171py","exitActive":"bottom-sheet__exitActive_171py","safeAreaBottom":"bottom-sheet__safeAreaBottom_171py","background-accent":"bottom-sheet__background-accent_171py","background-info":"bottom-sheet__background-info_171py","background-attention-muted":"bottom-sheet__background-attention-muted_171py","background-positive-muted":"bottom-sheet__background-positive-muted_171py","background-negative-muted":"bottom-sheet__background-negative-muted_171py","background-primary":"bottom-sheet__background-primary_171py","background-primary-inverted":"bottom-sheet__background-primary-inverted_171py","background-secondary":"bottom-sheet__background-secondary_171py","background-secondary-inverted":"bottom-sheet__background-secondary-inverted_171py","background-tertiary":"bottom-sheet__background-tertiary_171py","background-tertiary-inverted":"bottom-sheet__background-tertiary-inverted_171py","background-quaternary":"bottom-sheet__background-quaternary_171py","background-quaternary-inverted":"bottom-sheet__background-quaternary-inverted_171py","background-specialbg-component":"bottom-sheet__background-specialbg-component_171py","background-specialbg-component-inverted":"bottom-sheet__background-specialbg-component-inverted_171py","background-specialbg-primary-grouped":"bottom-sheet__background-specialbg-primary-grouped_171py","background-specialbg-secondary-grouped":"bottom-sheet__background-specialbg-secondary-grouped_171py","background-specialbg-tertiary-grouped":"bottom-sheet__background-specialbg-tertiary-grouped_171py","background-specialbg-secondary-transparent":"bottom-sheet__background-specialbg-secondary-transparent_171py","background-specialbg-secondary-transparent-inverted":"bottom-sheet__background-specialbg-secondary-transparent-inverted_171py","background-specialbg-tertiary-transparent":"bottom-sheet__background-specialbg-tertiary-transparent_171py","background-specialbg-tertiary-transparent-inverted":"bottom-sheet__background-specialbg-tertiary-transparent-inverted_171py"};
3
+ const styles = {"modal":"bottom-sheet__modal_wku8l","wrapper":"bottom-sheet__wrapper_wku8l","outerClassName":"bottom-sheet__outerClassName_wku8l","fullscreen":"bottom-sheet__fullscreen_wku8l","component":"bottom-sheet__component_wku8l","withTransition":"bottom-sheet__withTransition_wku8l","scrollableContainer":"bottom-sheet__scrollableContainer_wku8l","marker":"bottom-sheet__marker_wku8l","defaultMarker":"bottom-sheet__defaultMarker_wku8l","content":"bottom-sheet__content_wku8l","noHeader":"bottom-sheet__noHeader_wku8l","noFooter":"bottom-sheet__noFooter_wku8l","scrollLocked":"bottom-sheet__scrollLocked_wku8l","hiddenScrollbar":"bottom-sheet__hiddenScrollbar_wku8l","disabledPointerEvents":"bottom-sheet__disabledPointerEvents_wku8l","appear":"bottom-sheet__appear_wku8l","enter":"bottom-sheet__enter_wku8l","appearActive":"bottom-sheet__appearActive_wku8l","enterActive":"bottom-sheet__enterActive_wku8l","enterDone":"bottom-sheet__enterDone_wku8l","appearDone":"bottom-sheet__appearDone_wku8l","exit":"bottom-sheet__exit_wku8l","exitActive":"bottom-sheet__exitActive_wku8l","safeAreaBottom":"bottom-sheet__safeAreaBottom_wku8l","background-accent":"bottom-sheet__background-accent_wku8l","background-info":"bottom-sheet__background-info_wku8l","background-attention-muted":"bottom-sheet__background-attention-muted_wku8l","background-positive-muted":"bottom-sheet__background-positive-muted_wku8l","background-negative-muted":"bottom-sheet__background-negative-muted_wku8l","background-primary":"bottom-sheet__background-primary_wku8l","background-primary-inverted":"bottom-sheet__background-primary-inverted_wku8l","background-secondary":"bottom-sheet__background-secondary_wku8l","background-secondary-inverted":"bottom-sheet__background-secondary-inverted_wku8l","background-tertiary":"bottom-sheet__background-tertiary_wku8l","background-tertiary-inverted":"bottom-sheet__background-tertiary-inverted_wku8l","background-quaternary":"bottom-sheet__background-quaternary_wku8l","background-quaternary-inverted":"bottom-sheet__background-quaternary-inverted_wku8l","background-specialbg-component":"bottom-sheet__background-specialbg-component_wku8l","background-specialbg-component-inverted":"bottom-sheet__background-specialbg-component-inverted_wku8l","background-specialbg-primary-grouped":"bottom-sheet__background-specialbg-primary-grouped_wku8l","background-specialbg-secondary-grouped":"bottom-sheet__background-specialbg-secondary-grouped_wku8l","background-specialbg-tertiary-grouped":"bottom-sheet__background-specialbg-tertiary-grouped_wku8l","background-specialbg-secondary-transparent":"bottom-sheet__background-specialbg-secondary-transparent_wku8l","background-specialbg-secondary-transparent-inverted":"bottom-sheet__background-specialbg-secondary-transparent-inverted_wku8l","background-specialbg-tertiary-transparent":"bottom-sheet__background-specialbg-tertiary-transparent_wku8l","background-specialbg-tertiary-transparent-inverted":"bottom-sheet__background-specialbg-tertiary-transparent-inverted_wku8l"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -8,15 +8,15 @@
8
8
  --bottom-sheet-marker-color-inverted: var(--color-light-neutral-translucent-300-inverted);
9
9
  --bottom-sheet-text-color-inverted: var(--color-light-text-primary-inverted);
10
10
  }
11
- .bottom-sheet__component_2dbvi {
11
+ .bottom-sheet__component_eks4c {
12
12
  background-color: var(--bottom-sheet-background-color-inverted);
13
13
  }
14
- .bottom-sheet__content_2dbvi {
14
+ .bottom-sheet__content_eks4c {
15
15
  color: var(--bottom-sheet-text-color-inverted);
16
16
  }
17
- .bottom-sheet__defaultMarker_2dbvi {
17
+ .bottom-sheet__defaultMarker_eks4c {
18
18
  background-color: var(--bottom-sheet-marker-color-inverted);
19
19
  }
20
- .bottom-sheet__hasContent_2dbvi {
20
+ .bottom-sheet__hasContent_eks4c {
21
21
  color: var(--bottom-sheet-text-color-inverted);
22
22
  }
@@ -1,6 +1,6 @@
1
1
  import './inverted.css';
2
2
 
3
- const invertedColors = {"component":"bottom-sheet__component_2dbvi","content":"bottom-sheet__content_2dbvi","defaultMarker":"bottom-sheet__defaultMarker_2dbvi","hasContent":"bottom-sheet__hasContent_2dbvi"};
3
+ const invertedColors = {"component":"bottom-sheet__component_eks4c","content":"bottom-sheet__content_eks4c","defaultMarker":"bottom-sheet__defaultMarker_eks4c","hasContent":"bottom-sheet__hasContent_eks4c"};
4
4
 
5
5
  export { invertedColors as default };
6
6
  //# sourceMappingURL=inverted.module.css.js.map
@@ -10,7 +10,7 @@ const colorStyles = {
10
10
  default: defaultColors,
11
11
  inverted: invertedColors,
12
12
  };
13
- const Header = ({ className, colors = 'default', sticky, headerRef, headerOffset, showSwipeMarker, title, children, contentClassName, ...restProps }) => {
13
+ const Header = ({ className, colors = 'default', sticky, headerRef, headerOffset, showSwipeMarker, title, children, contentClassName, bottomAddons, ...restProps }) => {
14
14
  const { setHeaderOffset, setHasHeader, headerHighlighted, onClose } = useContext(BaseModalContext);
15
15
  useEffect(() => {
16
16
  setHeaderOffset(headerOffset);
@@ -19,8 +19,8 @@ const Header = ({ className, colors = 'default', sticky, headerRef, headerOffset
19
19
  setHasHeader(true);
20
20
  }, [setHasHeader]);
21
21
  const colorStyle = colorStyles[colors];
22
- const hasContent = Boolean(title || children);
23
- return (React.createElement(NavigationBarPrivate, { ...restProps, ref: headerRef, title: title, onClose: onClose, sticky: sticky, view: 'mobile', className: cn(className, {
22
+ const hasContent = Boolean(title || children || bottomAddons);
23
+ return (React.createElement(NavigationBarPrivate, { ...restProps, ref: headerRef, title: title, bottomAddons: bottomAddons, onClose: onClose, sticky: sticky, view: 'mobile', className: cn(className, {
24
24
  [styles.headerWrapper]: showSwipeMarker,
25
25
  [styles.headerWrapperWithoutSwipeMarker]: !showSwipeMarker,
26
26
  [colorStyle.highlighted]: hasContent && headerHighlighted && sticky,
@@ -1 +1 @@
1
- {"version":3,"file":"Component.js","sources":["../../../src/components/header/Component.tsx"],"sourcesContent":["import React, { type FC, type RefObject, useContext, useEffect } from 'react';\nimport cn from 'classnames';\n\nimport { BaseModalContext } from '@alfalab/core-components-base-modal';\nimport {\n NavigationBarPrivate,\n type NavigationBarPrivateProps,\n} from '@alfalab/core-components-navigation-bar-private';\n\nimport { type ColorType } from '../../types';\n\nimport defaultColors from './default.module.css';\nimport styles from './index.module.css';\nimport invertedColors from './inverted.module.css';\n\nexport type HeaderProps = Omit<NavigationBarPrivateProps, 'view' | 'size'> & {\n headerRef: RefObject<HTMLDivElement>;\n headerOffset: number;\n colors?: ColorType;\n showSwipeMarker?: boolean;\n};\n\nconst colorStyles = {\n default: defaultColors,\n inverted: invertedColors,\n} as const;\n\nexport const Header: FC<HeaderProps> = ({\n className,\n colors = 'default',\n sticky,\n headerRef,\n headerOffset,\n showSwipeMarker,\n title,\n children,\n contentClassName,\n ...restProps\n}) => {\n const { setHeaderOffset, setHasHeader, headerHighlighted, onClose } =\n useContext(BaseModalContext);\n\n useEffect(() => {\n setHeaderOffset(headerOffset);\n }, [headerOffset, setHeaderOffset]);\n\n useEffect(() => {\n setHasHeader(true);\n }, [setHasHeader]);\n\n const colorStyle = colorStyles[colors];\n const hasContent = Boolean(title || children);\n\n return (\n <NavigationBarPrivate\n {...restProps}\n ref={headerRef}\n title={title}\n onClose={onClose}\n sticky={sticky}\n view='mobile'\n className={cn(className, {\n [styles.headerWrapper]: showSwipeMarker,\n [styles.headerWrapperWithoutSwipeMarker]: !showSwipeMarker,\n [colorStyle.highlighted]: hasContent && headerHighlighted && sticky,\n [colorStyle.hasContent]: hasContent,\n [styles.sticky]: sticky,\n })}\n contentClassName={cn(styles.title, contentClassName)}\n titleClassName={cn(colorStyle.title)}\n subtitleClassName={cn(styles.subtitle, colorStyle.subtitle)}\n colors={colors}\n >\n {children}\n </NavigationBarPrivate>\n );\n};\n"],"names":[],"mappings":";;;;;;;;AAsBA,MAAM,WAAW,GAAG;AAChB,IAAA,OAAO,EAAE,aAAa;AACtB,IAAA,QAAQ,EAAE,cAAc;CAClB;AAEH,MAAM,MAAM,GAAoB,CAAC,EACpC,SAAS,EACT,MAAM,GAAG,SAAS,EAClB,MAAM,EACN,SAAS,EACT,YAAY,EACZ,eAAe,EACf,KAAK,EACL,QAAQ,EACR,gBAAgB,EAChB,GAAG,SAAS,EACf,KAAI;AACD,IAAA,MAAM,EAAE,eAAe,EAAE,YAAY,EAAE,iBAAiB,EAAE,OAAO,EAAE,GAC/D,UAAU,CAAC,gBAAgB,CAAC;IAEhC,SAAS,CAAC,MAAK;QACX,eAAe,CAAC,YAAY,CAAC;AACjC,KAAC,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC,CAAC;IAEnC,SAAS,CAAC,MAAK;QACX,YAAY,CAAC,IAAI,CAAC;AACtB,KAAC,EAAE,CAAC,YAAY,CAAC,CAAC;AAElB,IAAA,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,CAAC;IACtC,MAAM,UAAU,GAAG,OAAO,CAAC,KAAK,IAAI,QAAQ,CAAC;AAE7C,IAAA,QACI,KAAA,CAAA,aAAA,CAAC,oBAAoB,EAAA,EAAA,GACb,SAAS,EACb,GAAG,EAAE,SAAS,EACd,KAAK,EAAE,KAAK,EACZ,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,EACd,IAAI,EAAC,QAAQ,EACb,SAAS,EAAE,EAAE,CAAC,SAAS,EAAE;AACrB,YAAA,CAAC,MAAM,CAAC,aAAa,GAAG,eAAe;AACvC,YAAA,CAAC,MAAM,CAAC,+BAA+B,GAAG,CAAC,eAAe;YAC1D,CAAC,UAAU,CAAC,WAAW,GAAG,UAAU,IAAI,iBAAiB,IAAI,MAAM;AACnE,YAAA,CAAC,UAAU,CAAC,UAAU,GAAG,UAAU;AACnC,YAAA,CAAC,MAAM,CAAC,MAAM,GAAG,MAAM;AAC1B,SAAA,CAAC,EACF,gBAAgB,EAAE,EAAE,CAAC,MAAM,CAAC,KAAK,EAAE,gBAAgB,CAAC,EACpD,cAAc,EAAE,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,EACpC,iBAAiB,EAAE,EAAE,CAAC,MAAM,CAAC,QAAQ,EAAE,UAAU,CAAC,QAAQ,CAAC,EAC3D,MAAM,EAAE,MAAM,IAEb,QAAQ,CACU;AAE/B;;;;"}
1
+ {"version":3,"file":"Component.js","sources":["../../../src/components/header/Component.tsx"],"sourcesContent":["import React, { type FC, type RefObject, useContext, useEffect } from 'react';\nimport cn from 'classnames';\n\nimport { BaseModalContext } from '@alfalab/core-components-base-modal';\nimport {\n NavigationBarPrivate,\n type NavigationBarPrivateProps,\n} from '@alfalab/core-components-navigation-bar-private';\n\nimport { type ColorType } from '../../types';\n\nimport defaultColors from './default.module.css';\nimport styles from './index.module.css';\nimport invertedColors from './inverted.module.css';\n\nexport type HeaderProps = Omit<NavigationBarPrivateProps, 'view' | 'size'> & {\n headerRef: RefObject<HTMLDivElement>;\n headerOffset: number;\n colors?: ColorType;\n showSwipeMarker?: boolean;\n};\n\nconst colorStyles = {\n default: defaultColors,\n inverted: invertedColors,\n} as const;\n\nexport const Header: FC<HeaderProps> = ({\n className,\n colors = 'default',\n sticky,\n headerRef,\n headerOffset,\n showSwipeMarker,\n title,\n children,\n contentClassName,\n bottomAddons,\n ...restProps\n}) => {\n const { setHeaderOffset, setHasHeader, headerHighlighted, onClose } =\n useContext(BaseModalContext);\n\n useEffect(() => {\n setHeaderOffset(headerOffset);\n }, [headerOffset, setHeaderOffset]);\n\n useEffect(() => {\n setHasHeader(true);\n }, [setHasHeader]);\n\n const colorStyle = colorStyles[colors];\n const hasContent = Boolean(title || children || bottomAddons);\n\n return (\n <NavigationBarPrivate\n {...restProps}\n ref={headerRef}\n title={title}\n bottomAddons={bottomAddons}\n onClose={onClose}\n sticky={sticky}\n view='mobile'\n className={cn(className, {\n [styles.headerWrapper]: showSwipeMarker,\n [styles.headerWrapperWithoutSwipeMarker]: !showSwipeMarker,\n [colorStyle.highlighted]: hasContent && headerHighlighted && sticky,\n [colorStyle.hasContent]: hasContent,\n [styles.sticky]: sticky,\n })}\n contentClassName={cn(styles.title, contentClassName)}\n titleClassName={cn(colorStyle.title)}\n subtitleClassName={cn(styles.subtitle, colorStyle.subtitle)}\n colors={colors}\n >\n {children}\n </NavigationBarPrivate>\n );\n};\n"],"names":[],"mappings":";;;;;;;;AAsBA,MAAM,WAAW,GAAG;AAChB,IAAA,OAAO,EAAE,aAAa;AACtB,IAAA,QAAQ,EAAE,cAAc;CAClB;AAEH,MAAM,MAAM,GAAoB,CAAC,EACpC,SAAS,EACT,MAAM,GAAG,SAAS,EAClB,MAAM,EACN,SAAS,EACT,YAAY,EACZ,eAAe,EACf,KAAK,EACL,QAAQ,EACR,gBAAgB,EAChB,YAAY,EACZ,GAAG,SAAS,EACf,KAAI;AACD,IAAA,MAAM,EAAE,eAAe,EAAE,YAAY,EAAE,iBAAiB,EAAE,OAAO,EAAE,GAC/D,UAAU,CAAC,gBAAgB,CAAC;IAEhC,SAAS,CAAC,MAAK;QACX,eAAe,CAAC,YAAY,CAAC;AACjC,KAAC,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC,CAAC;IAEnC,SAAS,CAAC,MAAK;QACX,YAAY,CAAC,IAAI,CAAC;AACtB,KAAC,EAAE,CAAC,YAAY,CAAC,CAAC;AAElB,IAAA,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,CAAC;IACtC,MAAM,UAAU,GAAG,OAAO,CAAC,KAAK,IAAI,QAAQ,IAAI,YAAY,CAAC;AAE7D,IAAA,QACI,KAAA,CAAA,aAAA,CAAC,oBAAoB,EAAA,EAAA,GACb,SAAS,EACb,GAAG,EAAE,SAAS,EACd,KAAK,EAAE,KAAK,EACZ,YAAY,EAAE,YAAY,EAC1B,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,EACd,IAAI,EAAC,QAAQ,EACb,SAAS,EAAE,EAAE,CAAC,SAAS,EAAE;AACrB,YAAA,CAAC,MAAM,CAAC,aAAa,GAAG,eAAe;AACvC,YAAA,CAAC,MAAM,CAAC,+BAA+B,GAAG,CAAC,eAAe;YAC1D,CAAC,UAAU,CAAC,WAAW,GAAG,UAAU,IAAI,iBAAiB,IAAI,MAAM;AACnE,YAAA,CAAC,UAAU,CAAC,UAAU,GAAG,UAAU;AACnC,YAAA,CAAC,MAAM,CAAC,MAAM,GAAG,MAAM;AAC1B,SAAA,CAAC,EACF,gBAAgB,EAAE,EAAE,CAAC,MAAM,CAAC,KAAK,EAAE,gBAAgB,CAAC,EACpD,cAAc,EAAE,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,EACpC,iBAAiB,EAAE,EAAE,CAAC,MAAM,CAAC,QAAQ,EAAE,UAAU,CAAC,QAAQ,CAAC,EAC3D,MAAM,EAAE,MAAM,IAEb,QAAQ,CACU;AAE/B;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfalab/core-components-bottom-sheet",
3
- "version": "8.0.1",
3
+ "version": "8.0.2",
4
4
  "description": "Bottom sheet mobile component",
5
5
  "keywords": [],
6
6
  "license": "MIT",
@@ -35,6 +35,7 @@ export const Header: FC<HeaderProps> = ({
35
35
  title,
36
36
  children,
37
37
  contentClassName,
38
+ bottomAddons,
38
39
  ...restProps
39
40
  }) => {
40
41
  const { setHeaderOffset, setHasHeader, headerHighlighted, onClose } =
@@ -49,13 +50,14 @@ export const Header: FC<HeaderProps> = ({
49
50
  }, [setHasHeader]);
50
51
 
51
52
  const colorStyle = colorStyles[colors];
52
- const hasContent = Boolean(title || children);
53
+ const hasContent = Boolean(title || children || bottomAddons);
53
54
 
54
55
  return (
55
56
  <NavigationBarPrivate
56
57
  {...restProps}
57
58
  ref={headerRef}
58
59
  title={title}
60
+ bottomAddons={bottomAddons}
59
61
  onClose={onClose}
60
62
  sticky={sticky}
61
63
  view='mobile'