react-native-terra-ui 0.11.9 → 0.11.11

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 (29) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/lib/module/components/box/Box.js +35 -10
  3. package/lib/module/components/box/Box.js.map +1 -1
  4. package/lib/module/components/header/parts/HeaderGradientOverlay.js +17 -75
  5. package/lib/module/components/header/parts/HeaderGradientOverlay.js.map +1 -1
  6. package/lib/module/components/header/parts/HeaderSurface.js +19 -34
  7. package/lib/module/components/header/parts/HeaderSurface.js.map +1 -1
  8. package/lib/module/components/header/variants/LargeTitleHeader/index.js +15 -15
  9. package/lib/module/components/header/variants/LargeTitleHeader/index.js.map +1 -1
  10. package/lib/module/components/header/variants/TitleHeader/index.js +2 -3
  11. package/lib/module/components/header/variants/TitleHeader/index.js.map +1 -1
  12. package/lib/typescript/src/components/box/Box.d.ts +28 -4
  13. package/lib/typescript/src/components/box/Box.d.ts.map +1 -1
  14. package/lib/typescript/src/components/header/parts/HeaderGradientOverlay.d.ts +9 -14
  15. package/lib/typescript/src/components/header/parts/HeaderGradientOverlay.d.ts.map +1 -1
  16. package/lib/typescript/src/components/header/parts/HeaderSurface.d.ts +10 -7
  17. package/lib/typescript/src/components/header/parts/HeaderSurface.d.ts.map +1 -1
  18. package/lib/typescript/src/components/header/variants/LargeTitleHeader/index.d.ts.map +1 -1
  19. package/lib/typescript/src/components/header/variants/TitleHeader/index.d.ts.map +1 -1
  20. package/lib/typescript/src/components/surface/Surface.d.ts +1 -1
  21. package/lib/typescript/src/components/surface/Surface.d.ts.map +1 -1
  22. package/lib/typescript/src/components/toast/Toast.d.ts +1 -1
  23. package/lib/typescript/src/components/toast/Toast.d.ts.map +1 -1
  24. package/package.json +1 -1
  25. package/src/components/box/Box.tsx +59 -16
  26. package/src/components/header/parts/HeaderGradientOverlay.tsx +11 -69
  27. package/src/components/header/parts/HeaderSurface.tsx +16 -29
  28. package/src/components/header/variants/LargeTitleHeader/index.tsx +18 -13
  29. package/src/components/header/variants/TitleHeader/index.tsx +2 -5
package/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.11.11](https://github.com/earthlin9/react-native-terra-ui/compare/v0.11.10...v0.11.11) (2026-09-17)
4
+
5
+ ### Features
6
+
7
+ * **ui:** [box] cast the rendered element with an `as` prop ([9f294bb](https://github.com/earthlin9/react-native-terra-ui/commit/9f294bbff87e1a49454f0f1defb255f7f7df2cda))
8
+ * **ui:** [header] keep the background fade inside the surface ([85062d0](https://github.com/earthlin9/react-native-terra-ui/commit/85062d08af02920a8fa3671c4339d54e4915caea))
9
+
10
+ ## [0.11.10](https://github.com/earthlin9/react-native-terra-ui/compare/v0.11.9...v0.11.10) (2026-09-15)
11
+
12
+ ### Bug Fixes
13
+
14
+ * **ui:** [header] give the large title a gap only when an accessory follows ([b26f812](https://github.com/earthlin9/react-native-terra-ui/commit/b26f812702da03810b9f7924b07f98bb84b81c6d))
15
+
3
16
  ## [0.11.9](https://github.com/earthlin9/react-native-terra-ui/compare/v0.11.8...v0.11.9) (2026-09-15)
4
17
 
5
18
  ### Features
@@ -5,14 +5,20 @@ import { forwardRef } from "react";
5
5
  import { StyleSheet, useUnistyles } from "react-native-unistyles";
6
6
  import { Slot } from "../slot/index.js";
7
7
  import { BOX_STYLE_PROP_KEYS, resolveBoxStyle } from "./utils.js";
8
- import { jsx as _jsx } from "react/jsx-runtime";
9
- const STYLE_KEYS = new Set(BOX_STYLE_PROP_KEYS);
8
+
9
+ /** Props owned by Box itself — everything else belongs to the rendered element. */
10
10
 
11
11
  /**
12
- * Base layout primitive: a `View` styled through theme-token props.
13
- * The only component family exposing token style-props.
12
+ * Props of `Box` when cast as `T`. Token style-props plus everything the
13
+ * rendered component accepts — `<Box as={Pressable} onPress={…} />` type-checks
14
+ * against `Pressable`, not `View`.
14
15
  */
15
- export const Box = /*#__PURE__*/forwardRef(function Box({
16
+
17
+ /** Erased prop shape the implementation works with — the generic lives on the exported cast. */
18
+ import { jsx as _jsx } from "react/jsx-runtime";
19
+ const STYLE_KEYS = new Set(BOX_STYLE_PROP_KEYS);
20
+ const BoxWithRef = /*#__PURE__*/forwardRef(function Box({
21
+ as,
16
22
  asChild,
17
23
  style,
18
24
  children,
@@ -22,31 +28,50 @@ export const Box = /*#__PURE__*/forwardRef(function Box({
22
28
  theme
23
29
  } = useUnistyles();
24
30
  const styleProps = {};
25
- const viewProps = {};
31
+ const elementProps = {};
26
32
  for (const key of Object.keys(rest)) {
27
33
  const value = rest[key];
28
- if (STYLE_KEYS.has(key)) styleProps[key] = value;else viewProps[key] = value;
34
+ if (STYLE_KEYS.has(key)) styleProps[key] = value;else elementProps[key] = value;
29
35
  }
30
36
  const mergedStyle = [styles.root, resolveBoxStyle(styleProps, theme), style];
31
37
  if (asChild) {
32
38
  return /*#__PURE__*/_jsx(Slot, {
33
39
  ownerName: "Box",
34
40
  slotProps: {
35
- ...viewProps,
41
+ ...elementProps,
36
42
  style: mergedStyle,
37
43
  ref
38
44
  },
39
45
  children: children
40
46
  });
41
47
  }
42
- return /*#__PURE__*/_jsx(View, {
48
+ const Component = as ?? View;
49
+ return /*#__PURE__*/_jsx(Component, {
43
50
  ref: ref,
44
51
  style: mergedStyle,
45
- ...viewProps,
52
+ ...elementProps,
46
53
  children: children
47
54
  });
48
55
  });
49
56
 
57
+ /**
58
+ * Base layout primitive: a `View` styled through theme-token props.
59
+ * The only component family exposing token style-props.
60
+ *
61
+ * Pass `as` to cast it as another component — the token style-props still
62
+ * resolve, and the rest of the props are typed against that component.
63
+ * Note that `as` renders a component Box does not own, so a Unistyles style
64
+ * handed to it only stays theme-reactive if that component's own module runs
65
+ * through the Unistyles Babel plugin (see the stylesheet note below).
66
+ *
67
+ * @example
68
+ * ```tsx
69
+ * <Box row gap="2" p="4" />
70
+ * <Box as={Pressable} onPress={onPress} p="3" radius="md" />
71
+ * ```
72
+ */
73
+ export const Box = BoxWithRef;
74
+
50
75
  // ─── Styles ───────────────────────────────────────────────────────────────────
51
76
  //
52
77
  // Box has no static style of its own — this stylesheet exists so the
@@ -1 +1 @@
1
- {"version":3,"names":["forwardRef","StyleSheet","useUnistyles","Slot","BOX_STYLE_PROP_KEYS","resolveBoxStyle","jsx","_jsx","STYLE_KEYS","Set","Box","asChild","style","children","rest","ref","theme","styleProps","viewProps","key","Object","keys","value","has","mergedStyle","styles","root","ownerName","slotProps","View","create"],"sourceRoot":"../../../../src","sources":["components/box/Box.tsx"],"mappings":";;;AAAA,SAA4BA,UAAU,QAAQ,OAAO;AAGrD,SAASC,UAAU,EAAEC,YAAY,QAAQ,wBAAwB;AAEjE,SAASC,IAAI;AACb,SAASC,mBAAmB,EAAsBC,eAAe;AAAkB,SAAAC,GAAA,IAAAC,IAAA;AAOnF,MAAMC,UAAU,GAAG,IAAIC,GAAG,CAASL,mBAAwC,CAAC;;AAE5E;AACA;AACA;AACA;AACA,OAAO,MAAMM,GAAG,gBAAGV,UAAU,CAAsC,SAASU,GAAGA,CAC7E;EAAEC,OAAO;EAAEC,KAAK;EAAEC,QAAQ;EAAE,GAAGC;AAAK,CAAC,EACrCC,GAAG,EACH;EACA,MAAM;IAAEC;EAAM,CAAC,GAAGd,YAAY,CAAC,CAAC;EAEhC,MAAMe,UAAmC,GAAG,CAAC,CAAC;EAC9C,MAAMC,SAAkC,GAAG,CAAC,CAAC;EAC7C,KAAK,MAAMC,GAAG,IAAIC,MAAM,CAACC,IAAI,CAACP,IAAI,CAAC,EAAE;IACnC,MAAMQ,KAAK,GAAIR,IAAI,CAA6BK,GAAG,CAAC;IACpD,IAAIX,UAAU,CAACe,GAAG,CAACJ,GAAG,CAAC,EAAEF,UAAU,CAACE,GAAG,CAAC,GAAGG,KAAK,CAAC,KAC5CJ,SAAS,CAACC,GAAG,CAAC,GAAGG,KAAK;EAC7B;EAEA,MAAME,WAAW,GAAG,CAACC,MAAM,CAACC,IAAI,EAAErB,eAAe,CAACY,UAAU,EAAmBD,KAAK,CAAC,EAAEJ,KAAK,CAAC;EAE7F,IAAID,OAAO,EAAE;IACX,oBACEJ,IAAA,CAACJ,IAAI;MAACwB,SAAS,EAAC,KAAK;MAACC,SAAS,EAAE;QAAE,GAAGV,SAAS;QAAEN,KAAK,EAAEY,WAAW;QAAET;MAAI,CAAE;MAAAF,QAAA,EACxEA;IAAQ,CACL,CAAC;EAEX;EAEA,oBACEN,IAAA,CAACsB,IAAI;IAACd,GAAG,EAAEA,GAAI;IAACH,KAAK,EAAEY,WAAY;IAAA,GAAMN,SAAS;IAAAL,QAAA,EAC/CA;EAAQ,CACL,CAAC;AAEX,CAAC,CAAC;;AAEF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMY,MAAM,GAAGxB,UAAU,CAAC6B,MAAM,CAAC,OAAO;EAAEJ,IAAI,EAAE,CAAC;AAAE,CAAC,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["forwardRef","StyleSheet","useUnistyles","Slot","BOX_STYLE_PROP_KEYS","resolveBoxStyle","jsx","_jsx","STYLE_KEYS","Set","BoxWithRef","Box","as","asChild","style","children","rest","ref","theme","styleProps","elementProps","key","Object","keys","value","has","mergedStyle","styles","root","ownerName","slotProps","Component","View","create"],"sourceRoot":"../../../../src","sources":["components/box/Box.tsx"],"mappings":";;;AAAA,SAGEA,UAAU,QAGL,OAAO;AAGd,SAASC,UAAU,EAAEC,YAAY,QAAQ,wBAAwB;AAEjE,SAASC,IAAI;AACb,SAASC,mBAAmB,EAAsBC,eAAe;;AAEjE;;AAMA;AACA;AACA;AACA;AACA;;AAMA;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAQA,MAAMC,UAAU,GAAG,IAAIC,GAAG,CAASL,mBAAwC,CAAC;AAE5E,MAAMM,UAAU,gBAAGV,UAAU,CAA0B,SAASW,GAAGA,CACjE;EAAEC,EAAE;EAAEC,OAAO;EAAEC,KAAK;EAAEC,QAAQ;EAAE,GAAGC;AAAqB,CA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CAAC,CAAC,CAAC","ignoreList":[]}
@@ -4,80 +4,18 @@ import { useId } from "react";
4
4
  import Svg, { Defs, Rect, Stop, LinearGradient as SvgLinearGradient } from "react-native-svg";
5
5
 
6
6
  /**
7
- * How far the overlay extends below the bar's bottom edge, in dp.
8
- *
9
- * The fade needs more room than the bar alone can give it: confined to the bar,
10
- * the curve has to be steep enough to read as a band. Overhanging lets the tail
11
- * finish in open space, so the header releases content instead of cutting it.
7
+ * Opacity at the overlay's bottom edge. The top is fully opaque, so the header
8
+ * thins slightly toward the boundary rather than cutting content off square —
9
+ * but never far enough to read as see-through.
12
10
  */
13
11
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
14
- export const HEADER_FADE_EXTENT = 8;
15
-
16
- /**
17
- * Where the fade begins, as a fraction of the overlay's height — the bar plus
18
- * {@link HEADER_FADE_EXTENT}.
19
- *
20
- * Sits inside the bar rather than at its bottom edge, so the tint has already
21
- * begun thinning before content reaches the boundary. That is the trade this
22
- * value makes: a longer, gentler ramp, paid for with content being faintly
23
- * visible through the lower part of the bar.
24
- */
25
- const FADE_START = 0.5;
26
-
27
- /**
28
- * Stops used to approximate the fade curve. Below ~10 the ramp shows as a series
29
- * of bands on an 8-bit display; above ~14 the extra stops cost SVG parse time
30
- * with nothing visible in return.
31
- */
32
- const FADE_STOPS = 4;
33
-
34
- /** Ceiling on the fade's opacity — see {@link alphaAt}. */
35
- const MAX_FADE_ALPHA = 0.65;
36
-
12
+ export const HEADER_FADE_END_OPACITY = 0.85;
37
13
  /**
38
- * Raised cosine, capped at {@link MAX_FADE_ALPHA}, reaching 0 at the overlay's
39
- * bottom.
14
+ * Vertical fade behind header content, shared by header variants.
40
15
  *
41
- * The curve's slope is zero at both ends, so neither the start of the fade nor
42
- * its finish leaves a seam. A two-stop linear ramp has a constant slope that
43
- * begins and ends abruptly, and those two hard edges are what read as a line
44
- * drawn across the content rather than the header letting go of it.
45
- *
46
- * The cap holds the ramp just short of solid, so the whole overlay reads as one
47
- * continuous gradient rather than an opaque plateau with a curve bolted on.
48
- */
49
- const alphaAt = t => (1 + Math.cos(Math.PI * t) * MAX_FADE_ALPHA) / 2;
50
-
51
- /**
52
- * Every input is a module constant, so the ramp is built once at load rather
53
- * than rebuilt per render.
54
- *
55
- * The leading stop belongs to this list rather than being a sibling element:
56
- * `LinearGradient` types its children as a flat `ReactElement[]`, so an element
57
- * beside a mapped array would nest and fail to type-check.
58
- */
59
- const STOPS = [{
60
- offset: 0,
61
- opacity: 1
62
- }, ...Array.from({
63
- length: FADE_STOPS
64
- }, (_, index) => {
65
- const t = index / (FADE_STOPS - 1);
66
- const offset = FADE_START + t * (1 - FADE_START);
67
- return {
68
- offset,
69
- opacity: offset === 1 ? 0 : alphaAt(t)
70
- };
71
- })];
72
- /**
73
- * Vertical fade-out overlay behind header content, shared by header variants.
74
- *
75
- * Reaches zero rather than stopping short. An overlay ending at partial opacity
76
- * leaves a hard step wherever it is clipped, and that step is far more visible
77
- * than the fade it was meant to hide — it is what cuts content off square as it
78
- * scrolls under the header.
79
- *
80
- * Callers size it to overhang the bar by {@link HEADER_FADE_EXTENT}.
16
+ * A two-stop linear ramp spanning the overlay's own box: it neither overhangs
17
+ * the surface nor reserves a band inside it, so callers size the surface and
18
+ * the ramp simply spans whatever they gave it.
81
19
  */
82
20
  export function HeaderGradientOverlay({
83
21
  color
@@ -87,17 +25,21 @@ export function HeaderGradientOverlay({
87
25
  height: "100%",
88
26
  width: "100%",
89
27
  children: [/*#__PURE__*/_jsx(Defs, {
90
- children: /*#__PURE__*/_jsx(SvgLinearGradient, {
28
+ children: /*#__PURE__*/_jsxs(SvgLinearGradient, {
91
29
  id: gradientId,
92
30
  x1: "0",
93
31
  y1: "0",
94
32
  x2: "0",
95
33
  y2: "1",
96
- children: STOPS.map(stop => /*#__PURE__*/_jsx(Stop, {
97
- offset: stop.offset,
34
+ children: [/*#__PURE__*/_jsx(Stop, {
35
+ offset: 0,
36
+ stopColor: color,
37
+ stopOpacity: 1
38
+ }), /*#__PURE__*/_jsx(Stop, {
39
+ offset: 1,
98
40
  stopColor: color,
99
- stopOpacity: stop.opacity
100
- }, stop.offset))
41
+ stopOpacity: HEADER_FADE_END_OPACITY
42
+ })]
101
43
  })
102
44
  }), /*#__PURE__*/_jsx(Rect, {
103
45
  width: "100%",
@@ -1 +1 @@
1
- {"version":3,"names":["useId","Svg","Defs","Rect","Stop","LinearGradient","SvgLinearGradient","jsx","_jsx","jsxs","_jsxs","HEADER_FADE_EXTENT","FADE_START","FADE_STOPS","MAX_FADE_ALPHA","alphaAt","t","Math","cos","PI","STOPS","offset","opacity","Array","from","length","_","index","HeaderGradientOverlay","color","gradientId","height","width","children","id","x1","y1","x2","y2","map","stop","stopColor","stopOpacity","fill"],"sourceRoot":"../../../../../src","sources":["components/header/parts/HeaderGradientOverlay.tsx"],"mappings":";;AAAA,SAASA,KAAK,QAAQ,OAAO;AAE7B,OAAOC,GAAG,IAAIC,IAAI,EAAEC,IAAI,EAAEC,IAAI,EAAEC,cAAc,IAAIC,iBAAiB,QAAQ,kBAAkB;;AAE7F;AACA;AACA;AACA;AACA;AACA;AACA;AANA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAOA,OAAO,MAAMC,kBAAkB,GAAG,CAAC;;AAEnC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,UAAU,GAAG,GAAG;;AAEtB;AACA;AACA;AACA;AACA;AACA,MAAMC,UAAU,GAAG,CAAC;;AAEpB;AACA,MAAMC,cAAc,GAAG,IAAI;;AAE3B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,OAAO,GAAIC,CAAS,IAAK,CAAC,CAAC,GAAGC,IAAI,CAACC,GAAG,CAACD,IAAI,CAACE,EAAE,GAAGH,CAAC,CAAC,GAAGF,cAAc,IAAI,CAAC;;AAE/E;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMM,K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,MAAM;MAACY,IAAI,EAAE,QAAQb,UAAU;IAAI,CAAE,CAAC;EAAA,CAC7D,CAAC;AAEV","ignoreList":[]}
1
+ {"version":3,"names":["useId","Svg","Defs","Rect","Stop","LinearGradient","SvgLinearGradient","jsx","_jsx","jsxs","_jsxs","HEADER_FADE_END_OPACITY","HeaderGradientOverlay","color","gradientId","height","width","children","id","x1","y1","x2","y2","offset","stopColor","stopOpacity","fill"],"sourceRoot":"../../../../../src","sources":["components/header/parts/HeaderGradientOverlay.tsx"],"mappings":";;AAAA,SAASA,KAAK,QAAQ,OAAO;AAE7B,OAAOC,GAAG,IAAIC,IAAI,EAAEC,IAAI,EAAEC,IAAI,EAAEC,cAAc,IAAIC,iBAAiB,QAAQ,kBAAkB;;AAE7F;AACA;AACA;AACA;AACA;AAJA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAKA,OAAO,MAAMC,uBAAuB,GAAG,IAAI;AAO3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,qBAAqBA,CAAC;EAAEC;AAAkC,CAAC,EAAE;EAC3E,MAAMC,UAAU,GAAGd,KAAK,CAAC,CAAC;EAE1B,oBACEU,KAAA,CAACT,GAAG;IAACc,MAAM,EAAC,MAAM;IAACC,KAAK,EAAC,MAAM;IAAAC,QAAA,gBAC7BT,IAAA,CAACN,IAAI;MAAAe,QAAA,eACHP,KAAA,CAACJ,iBAAiB;QAACY,EAAE,EAAEJ,UAAW;QAACK,EAAE,EAAC,GAAG;QAACC,EAAE,EAAC,GAAG;QAACC,EAAE,EAAC,GAAG;QAACC,EAAE,EAAC,GAAG;QAAAL,QAAA,gBAC5DT,IAAA,CAACJ,IAAI;UAACmB,MAAM,EAAE,CAAE;UAACC,SAAS,EAAEX,KAAM;UAACY,WAAW,EAAE;QAAE,CAAE,CAAC,eACrDjB,IAAA,CAACJ,IAAI;UAACmB,MAAM,EAAE,CAAE;UAACC,SAAS,EAAEX,KAAM;UAACY,WAAW,EAAEd;QAAwB,CAAE,CAAC;MAAA,CAC1D;IAAC,CAChB,CAAC,eACPH,IAAA,CAACL,IAAI;MAACa,KAAK,EAAC,MAAM;MAACD,MAAM,EAAC,MAAM;MAACW,IAAI,EAAE,QAAQZ,UAAU;IAAI,CAAE,CAAC;EAAA,CAC7D,CAAC;AAEV","ignoreList":[]}
@@ -3,56 +3,41 @@
3
3
  import { View } from "react-native-unistyles/components/native/View";
4
4
  import Animated from "react-native-reanimated";
5
5
  import { StyleSheet } from "react-native-unistyles";
6
- import { HEADER_FADE_EXTENT, HeaderGradientOverlay } from "./HeaderGradientOverlay.js";
7
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
6
+ import { HeaderGradientOverlay } from "./HeaderGradientOverlay.js";
7
+ import { jsx as _jsx } from "react/jsx-runtime";
8
8
  /**
9
- * Header background with a solid fill and a bottom gradient.
10
- * A fixed gradient height keeps tall accessories from becoming translucent.
9
+ * Header background covering the bar and any accessory as one surface, so
10
+ * content scrolling under the header meets a single boundary rather than two.
11
+ *
12
+ * The ramp spans the surface itself: it is sized by the caller and stays inside
13
+ * those bounds, so a taller surface stretches the fade rather than adding to it.
11
14
  */
12
15
  export function HeaderSurface({
13
16
  color,
14
17
  animatedStyle,
15
- fadeHeight
18
+ solid
16
19
  }) {
17
- return /*#__PURE__*/_jsxs(Animated.View, {
20
+ return /*#__PURE__*/_jsx(Animated.View, {
18
21
  style: [styles.surface, animatedStyle],
19
22
  pointerEvents: "none",
20
- children: [/*#__PURE__*/_jsx(View, {
21
- style: styles.fill(color, fadeHeight)
22
- }), /*#__PURE__*/_jsx(View, {
23
- style: styles.fade(fadeHeight),
24
- children: /*#__PURE__*/_jsx(HeaderGradientOverlay, {
25
- color: color
26
- })
27
- })]
23
+ children: solid ? /*#__PURE__*/_jsx(View, {
24
+ style: styles.fill(color)
25
+ }) : /*#__PURE__*/_jsx(HeaderGradientOverlay, {
26
+ color: color
27
+ })
28
28
  });
29
29
  }
30
- const styles = StyleSheet.create(theme => ({
31
- // Extend the fade below the header's layout bounds.
30
+ const styles = StyleSheet.create(() => ({
32
31
  surface: {
33
32
  position: "absolute",
34
33
  top: 0,
35
34
  left: 0,
36
35
  right: 0,
37
- bottom: -HEADER_FADE_EXTENT
36
+ bottom: 0
38
37
  },
39
- // Fill the region above the gradient.
40
- fill: (color, fadeHeight) => ({
41
- position: "absolute",
42
- top: 0,
43
- left: 0,
44
- right: 0,
45
- bottom: fadeHeight ?? theme.layout.header.height + HEADER_FADE_EXTENT,
46
- backgroundColor: color,
47
- uni__dependencies: [0]
48
- }),
49
- fade: fadeHeight => ({
50
- position: "absolute",
51
- left: 0,
52
- right: 0,
53
- bottom: 0,
54
- height: fadeHeight ?? theme.layout.header.height + HEADER_FADE_EXTENT,
55
- uni__dependencies: [0]
38
+ fill: color => ({
39
+ flex: 1,
40
+ backgroundColor: color
56
41
  })
57
42
  }));
58
43
  //# sourceMappingURL=HeaderSurface.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["Animated","StyleSheet","HEADER_FADE_EXTENT","HeaderGradientOverlay","jsx","_jsx","jsxs","_jsxs","HeaderSurface","color","animatedStyle","fadeHeight","View","style","styles","surface","pointerEvents","children","fill","fade","create","theme","position","top","left","right","bottom","layout","header","height","backgroundColor","uni__dependencies"],"sourceRoot":"../../../../../src","sources":["components/header/parts/HeaderSurface.tsx"],"mappings":";;;AAEA,OAAOA,QAAQ,MAAiC,yBAAyB;AACzE,SAASC,UAAU,QAAQ,wBAAwB;AAEnD,SAASC,kBAAkB,EAAEC,qBAAqB;AAAkC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAgBpF;AACA;AACA;AACA;AACA,OAAO,SAASC,aAAaA,CAAC;EAAEC,KAAK;EAAEC,aAAa;EAAEC;AAA+B,CAAC,EAAE;EACtF,oBACEJ,KAAA,CAACP,QAAQ,CAACY,IAAI;IAACC,KAAK,EAAE,CAACC,MAAM,CAACC,OAAO,EAAEL,a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HeaderSurface","color","animatedStyle","solid","View","style","styles","surface","pointerEvents","children","fill","create","position","top","left","right","bottom","flex","backgroundColor"],"sourceRoot":"../../../../../src","sources":["components/header/parts/HeaderSurface.tsx"],"mappings":";;;AAEA,OAAOA,QAAQ,MAAiC,yBAAyB;AACzE,SAASC,UAAU,QAAQ,wBAAwB;AAEnD,SAASC,qBAAqB;AAAkC,SAAAC,GAAA,IAAAC,IAAA;AAgBhE;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,aAAaA,CAAC;EAAEC,KAAK;EAAEC,aAAa;EAAEC;AAA0B,CAAC,EAAE;EACjF,oBACEJ,IAAA,CAACJ,QAAQ,CAACS,IAAI;IAACC,KAAK,EAAE,CAACC,MAAM,CAACC,OAAO,EAAEL,aAAa,CAAE;IAACM,aAAa,EAAC,MAAM;IAAAC,QAAA,EACxEN,KAAK,gBAAGJ,IAAA,CAACK,IAAI;MAACC,KAAK,EAAEC,MAAM,CAACI,IAAI,CAACT,KAAK;IAAE,CAAE,CAAC,gBAAGF,IAAA,CAACF,qBAAqB;MAACI,KAAK,EAAEA;IAAM,CAAE;EAAC,CACzE,CAAC;AAEpB;AAEA,MAAMK,MAAM,GAAGV,UAAU,CAACe,MAAM,CAAC,OAAO;EACtCJ,OAAO,EAAE;IACPK,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE,CAAC;IACNC,IAAI,EAAE,CAAC;IACPC,KAAK,EAAE,CAAC;IACRC,MAAM,EAAE;EACV,CAAC;EACDN,IAAI,EAAGT,KAAa,KAAM;IACxBgB,IAAI,EAAE,CAAC;IACPC,eAAe,EAAEjB;EACnB,CAAC;AACH,CAAC,CAAC,CAAC","ignoreList":[]}
@@ -13,7 +13,6 @@ import { SCREEN_HEADER_PORTAL_HOST, useScreen } from "../../../screen/ScreenCont
13
13
  import { Toolbar } from "../../../toolbar/index.js";
14
14
  import { HeaderDismissButton } from "../../header-buttons.js";
15
15
  import { HeaderAccessory, HeaderAccessorySpacer } from "../../parts/HeaderAccessory.js";
16
- import { HEADER_FADE_EXTENT } from "../../parts/HeaderGradientOverlay.js";
17
16
  import { HeaderSurface } from "../../parts/HeaderSurface.js";
18
17
  import { isCustomTitle, isTextTitle } from "../../utils.js";
19
18
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
@@ -27,6 +26,7 @@ function LargeTitlePortalContent({
27
26
  title,
28
27
  overline,
29
28
  subtitle,
29
+ hasAccessoryBelow,
30
30
  onHeightChange
31
31
  }) {
32
32
  const {
@@ -57,7 +57,7 @@ function LargeTitlePortalContent({
57
57
  // Layout height excludes the collapse transform.
58
58
  const handleLayout = event => onHeightChange?.(event.nativeEvent.layout.height);
59
59
  return /*#__PURE__*/_jsxs(Animated.View, {
60
- style: [styles.portalContent, largeTitleAnimatedStyle],
60
+ style: [styles.portalContent(hasAccessoryBelow), largeTitleAnimatedStyle],
61
61
  onLayout: handleLayout,
62
62
  children: [!!overline && /*#__PURE__*/_jsx(Text, {
63
63
  style: styles.overline,
@@ -128,7 +128,6 @@ export function LargeTitleHeader({
128
128
  const bgColor = (colorToken ? resolveThemeColor(colorToken, theme) : screenBackground) ?? theme.color["surface.canvas"];
129
129
  const leadingContent = leadingActions !== undefined ? leadingActions : LeftToolbar;
130
130
  const trailingContent = trailingActions !== undefined ? trailingActions : RightToolbar;
131
- const gradientColor = bgColor;
132
131
  const isSticky = accessoryBehavior === "sticky" && !isLargeTitleHidden;
133
132
  const hasStickyAccessory = isSticky && accessory != null;
134
133
  // Sticky accessories reserve space below the large title; pinned ones add top padding.
@@ -176,8 +175,8 @@ export function LargeTitleHeader({
176
175
  opacity: stickyAccessoryOffset > 0 ? interpolate(scrollY.value, [0, stickyAccessoryOffset], [1, 0], "clamp") : 0
177
176
  }));
178
177
 
179
- // Animate the gradient overlay's opacity: 0 (expanded) → 1 (collapsed).
180
- const gradientOpacityStyle = useAnimatedStyle(() => {
178
+ // Animate the header surface's opacity: 0 (expanded) → 1 (collapsed).
179
+ const surfaceOpacityStyle = useAnimatedStyle(() => {
181
180
  if (isLargeTitleHiddenValue.value) {
182
181
  return {
183
182
  opacity: 1
@@ -193,7 +192,7 @@ export function LargeTitleHeader({
193
192
  opacity: interpolate(scrollY.value, [0, height], [0, 1], "clamp")
194
193
  };
195
194
  });
196
- useHeaderBackground(bgColor, gradientOpacityStyle);
195
+ useHeaderBackground(bgColor, surfaceOpacityStyle);
197
196
  const compactTitleAnimatedStyle = useAnimatedStyle(() => {
198
197
  if (isLargeTitleHiddenValue.value) {
199
198
  return {
@@ -248,6 +247,7 @@ export function LargeTitleHeader({
248
247
  title: title,
249
248
  overline: overline,
250
249
  subtitle: subtitle,
250
+ hasAccessoryBelow: hasStickyAccessory,
251
251
  onHeightChange: isSticky ? handleLargeTitleHeightChange : undefined
252
252
  }), isSticky && accessory != null && /*#__PURE__*/_jsx(HeaderAccessorySpacer, {
253
253
  height: stickyAccessoryHeight
@@ -256,14 +256,14 @@ export function LargeTitleHeader({
256
256
  style: [styles.stickySurface, stickySurfaceStyle],
257
257
  pointerEvents: "none",
258
258
  children: /*#__PURE__*/_jsx(HeaderSurface, {
259
- color: gradientColor,
260
- animatedStyle: gradientOpacityStyle
259
+ color: bgColor,
260
+ animatedStyle: surfaceOpacityStyle
261
261
  })
262
262
  }), /*#__PURE__*/_jsxs(View, {
263
263
  style: styles.barGroup,
264
264
  children: [!hasStickyAccessory && /*#__PURE__*/_jsx(HeaderSurface, {
265
- color: gradientColor,
266
- animatedStyle: gradientOpacityStyle
265
+ color: bgColor,
266
+ animatedStyle: surfaceOpacityStyle
267
267
  }), /*#__PURE__*/_jsxs(View, {
268
268
  style: styles.bar,
269
269
  children: [leading != null && /*#__PURE__*/_jsx(Toolbar, {
@@ -290,7 +290,7 @@ export function LargeTitleHeader({
290
290
  children: [/*#__PURE__*/_jsx(HeaderSurface, {
291
291
  color: screenBackground ?? theme.color["surface.canvas"],
292
292
  animatedStyle: accessorySurfaceStyle,
293
- fadeHeight: HEADER_FADE_EXTENT
293
+ solid: true
294
294
  }), /*#__PURE__*/_jsx(HeaderAccessory, {
295
295
  padding: accessoryPadding,
296
296
  onHeightChange: handleAccessoryHeightChange,
@@ -349,13 +349,13 @@ const styles = StyleSheet.create(theme => ({
349
349
  },
350
350
  uni__dependencies: [4]
351
351
  },
352
- portalContent: {
352
+ portalContent: hasAccessoryBelow => ({
353
353
  gap: 2,
354
- minHeight: theme.layout.header.height,
355
- paddingBottom: theme.spacing["1"],
354
+ // Include the gap in the measured height used to position the accessory.
355
+ paddingBottom: hasAccessoryBelow ? theme.spacing["2"] : 0,
356
356
  paddingHorizontal: theme.layout.screen.padding.x,
357
357
  uni__dependencies: [0]
358
- },
358
+ }),
359
359
  overline: {
360
360
  fontSize: theme.typography.variants["label-sm"].fontSize,
361
361
  lineHeight: theme.typography.variants["label-sm"].lineHeight,
@@ -1 +1 @@
1
- {"version":3,"names":["useCallback","useEffect","useState","Animated","interpolate","useAnimatedStyle","useSharedValue","StyleSheet","useUnistyles","resolveThemeColor","FONT_WEIGHT_VALUE","Portal","useHeaderBackground","SCREEN_HEADER_PORTAL_HOST","useScreen","Toolbar","HeaderDismissButton","HeaderAccessory","HeaderAccessorySpacer","HEADER_FADE_EXTENT","HeaderSurface","isCustomTitle","isTextTitle","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","AnimatedText","createAnimatedComponent","Text","COMPACT_TITLE_SLIDE_OFFSET","LARGE_TITLE_SLIDE_OFFSET","LargeTitlePortalContent","title","overline","subtitle","onHeightChange","theme","scrollY","headerCollapseHeight","layout","header","height","largeTitleAnimatedStyle","opacity","transform","translateY","value","handleLayout","event","nativeEvent","View","style","styles","portalContent","onLayout","children","maxFontSizeMultiplier","typography","variants","largeTitle","LargeTitleHeader","leadingActions","trailingActions","LeftToolbar","RightToolbar","accessory","accessoryPadding","accessoryBehavior","dismissAction","navigation","onDismiss","titleAlignment","isLargeTitleHidden","background","bg","screenBackground","setHeaderAccessoryHeight","contentTopPadding","colorToken","bgColor","color","leadingContent","undefined","trailingContent","gradientColor","isSticky","hasStickyAccessory","stickyAccessoryHeight","setStickyAccessoryHeight","largeTitleHeight","setLargeTitleHeight","isLargeTitleHiddenValue","handleAccessoryHeightChange","Math","max","round","handleLargeTitleHeightChange","stickyAccessoryOffset","stickyAccessoryStyle","_styles","useVariants","stickySurfaceStyle","accessorySurfaceStyle","gradientOpacityStyle","compactTitleAnimatedStyle","leading","trailing","container","pointerEvents","hostName","stickySurface","animatedStyle","barGroup","bar","titleContainer","compactTitle","padding","stickyAccessory","fadeHeight","create","position","top","left","right","accessoryOffset","zIndex","paddingBottom","flexDirection","alignItems","paddingHorizontal","screen","x","gap","spacing","justifyContent","uni__dependencies","center","marginLeft","minHeight","fontSize","lineHeight","letterSpacing","fontWeight","textAlign","flex"],"sourceRoot":"../../../../../../src","sources":["components/header/variants/LargeTitleHeader/index.tsx"],"mappings":";;;;AAAA,SAASA,WAAW,EAAEC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAGxD,OAAOC,QAAQ,IAAIC,WAAW,EAAEC,gBAAgB,EAAEC,cAAc,QAAQ,yBAAyB;AACjG,SAASC,UAAU,EAAEC,YAAY,QAAQ,wBAAwB;AAEjE,SAASC,iBAAiB;AAC1B,SAASC,iBAAiB;AAC1B,SAASC,MAAM;AACf,SAASC,mBAAmB;AAC5B,SAASC,yBAAyB,EAAEC,SAAS;AAC7C,SAASC,OAAO;AAChB,SAASC,mBAAmB;AAC5B,SAASC,eAAe,EAAEC,qBAAqB;AAC/C,SAASC,kBAAkB;AAC3B,SAASC,aAAa;AAEtB,SAASC,aAAa,EAAEC,WAAW;AAAsB,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAGzD,MAAMC,YAAY,GAAG1B,QAAQ,CAAC2B,uBAAuB,CAACC,IAAI,CAAC;;AAE3D;AACA,MAAMC,0BAA0B,GAAG,CAAC;AACpC;AACA,MAAMC,wBAA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Q,CAAC,UAAU,CAAC,CAACmF,aAAa;IAClEC,UAAU,EAAEvI,iBAAiB,CAAC6B,KAAK,CAACqB,UAAU,CAACC,QAAQ,CAAC,UAAU,CAAC,CAACoF,UAAU,CAAC;IAC/E9D,KAAK,EAAG5C,KAAK,CAAC4C,KAAK,CAAmD,cAAc,CAAC,IAAI,EAAE;IAC3FtB,QAAQ,EAAE;MACRa,cAAc,EAAE;QACdiE,MAAM,EAAE;UAAEO,SAAS,EAAE;QAAS,CAAC;QAC/BrB,IAAI,EAAE;UAAEqB,SAAS,EAAE;QAAO;MAC5B;IACF,CAAC;IAAAR,iBAAA;EACH,CAAC;EACDrB,cAAc,EAAE;IACd8B,IAAI,EAAE,CAAC;IACPtF,QAAQ,EAAE;MACRa,cAAc,EAAE;QACdiE,MAAM,EAAE;UACNhB,QAAQ,EAAE,UAAU;UACpBE,IAAI,EAAE,CAAC;UACPC,KAAK,EAAE,CAAC;UACRK,UAAU,EAAE;QACd,CAAC;QACDN,IAAI,EAAE;UACJsB,IAAI,EAAE,CAAC;UACPhB,UAAU,EAAE;QACd;MACF;IACF,CAAC;IAAAO,iBAAA;EACH;AACF,CAAC,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["useCallback","useEffect","useState","Animated","interpolate","useAnimatedStyle","useSharedValue","StyleSheet","useUnistyles","resolveThemeColor","FONT_WEIGHT_VALUE","Portal","useHeaderBackground","SCREEN_HEADER_PORTAL_HOST","useScreen","Toolbar","HeaderDismissButton","HeaderAccessory","HeaderAccessorySpacer","HeaderSurface","isCustomTitle","isTextTitle","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","AnimatedText","createAnimatedComponent","Text","COMPACT_TITLE_SLIDE_OFFSET","LARGE_TITLE_SLIDE_OFFSET","LargeTitlePortalContent","title","overline","subtitle","hasAccessoryBelow","onHeightChange","theme","scrollY","headerCollapseHeight","layout","header","height","largeTitleAnimatedStyle","opacity","transform","translateY","value","handleLayout","event","nativeEvent","View","style","styles","portalContent","onLayout","children","maxFontSizeMultiplier","typography","variants","largeTitle","LargeTitleHeader","leadingActions","trailingActions","LeftToolbar","RightToolbar","accessory","accessoryPadding","accessoryBehavior","dismissAction","navigation","onDismiss","titleAlignment","isLargeTitleHidden","background","bg","screenBackground","setHeaderAccessoryHeight","contentTopPadding","colorToken","bgColor","color","leadingContent","undefined","trailingContent","isSticky","hasStickyAccessory","stickyAccessoryHeight","setStickyAccessoryHeight","largeTitleHeight","setLargeTitleHeight","isLargeTitleHiddenValue","handleAccessoryHeightChange","Math","max","round","handleLargeTitleHeightChange","stickyAccessoryOffset","stickyAccessoryStyle","_styles","useVariants","stickySurfaceStyle","accessorySurfaceStyle","surfaceOpacityStyle","compactTitleAnimatedStyle","leading","trailing","container","pointerEvents","hostName","stickySurface","animatedStyle","barGroup","bar","titleContainer","compactTitle","padding","stickyAccessory","solid","create","position","top","left","right","accessoryOffset","zIndex","paddingBottom","flexDirection","alignItems","paddingHorizontal","screen","x","gap","spacing","justifyContent","uni__dependencies","center","marginLeft","fontSize","lineHeight","letterSpacing","fontWeight","textAlign","flex"],"sourceRoot":"../../../../../../src","sources":["components/header/variants/LargeTitleHeader/index.tsx"],"mappings":";;;;AAAA,SAASA,WAAW,EAAEC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAGxD,OAAOC,QAAQ,IAAIC,WAAW,EAAEC,gBAAgB,EAAEC,cAAc,QAAQ,yBAAyB;AACjG,SAASC,UAAU,EAAEC,YAAY,QAAQ,wBAAwB;AAEjE,SAASC,iBAAiB;AAC1B,SAASC,iBAAiB;AAC1B,SAASC,MAAM;AACf,SAASC,mBAAmB;AAC5B,SAASC,yBAAyB,EAAEC,SAAS;AAC7C,SAASC,OAAO;AAChB,SAASC,mBAAmB;AAC5B,SAASC,eAAe,EAAEC,qBAAqB;AAC/C,SAASC,aAAa;AAEtB,SAASC,aAAa,EAAEC,WAAW;AAAsB,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EA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,QAAQ,CAAC,UAAU,CAAC,CAAC+E,QAAQ;IACxDC,UAAU,EAAEtG,KAAK,CAACqB,UAAU,CAACC,QAAQ,CAAC,UAAU,CAAC,CAACgF,UAAU;IAC5DC,aAAa,EAAEvG,KAAK,CAACqB,UAAU,CAACC,QAAQ,CAAC,UAAU,CAAC,CAACiF,aAAa;IAClEC,UAAU,EAAErI,iBAAiB,CAAC6B,KAAK,CAACqB,UAAU,CAACC,QAAQ,CAAC,UAAU,CAAC,CAACkF,UAAU,CAAC;IAC/E5D,KAAK,EAAG5C,KAAK,CAAC4C,KAAK,CAAmD,cAAc,CAAC,IAAI,EAAE;IAC3FtB,QAAQ,EAAE;MACRa,cAAc,EAAE;QACdgE,MAAM,EAAE;UAAEM,SAAS,EAAE;QAAS,CAAC;QAC/BpB,IAAI,EAAE;UAAEoB,SAAS,EAAE;QAAO;MAC5B;IACF,CAAC;IAAAP,iBAAA;EACH,CAAC;EACDrB,cAAc,EAAE;IACd6B,IAAI,EAAE,CAAC;IACPpF,QAAQ,EAAE;MACRa,cAAc,EAAE;QACdgE,MAAM,EAAE;UACNhB,QAAQ,EAAE,UAAU;UACpBE,IAAI,EAAE,CAAC;UACPC,KAAK,EAAE,CAAC;UACRK,UAAU,EAAE;QACd,CAAC;QACDN,IAAI,EAAE;UACJqB,IAAI,EAAE,CAAC;UACPf,UAAU,EAAE;QACd;MACF;IACF,CAAC;IAAAO,iBAAA;EACH;AACF,CAAC,CAAC,CAAC","ignoreList":[]}
@@ -52,14 +52,13 @@ export function TitleHeader({
52
52
  const screen = useContext(ScreenContext);
53
53
  const colorToken = background ?? bg;
54
54
  const bgColor = (colorToken ? resolveThemeColor(colorToken, theme) : screen?.background) ?? theme.color["surface.canvas"];
55
- useHeaderBackground(bgColor);
56
55
  const leadingContent = leadingActions !== undefined ? leadingActions : LeftToolbar;
57
56
  const trailingContent = trailingActions !== undefined ? trailingActions : RightToolbar;
58
57
  const setAccessoryInset = screen?.setHeaderAccessoryHeight;
59
58
  // Compact headers always reserve the accessory height as top padding.
60
59
  const handleAccessoryHeightChange = useCallback(height => setAccessoryInset?.(height), [setAccessoryInset]);
61
60
  const isTransparent = bgColor === "transparent";
62
- const gradientColor = bgColor;
61
+ useHeaderBackground(bgColor);
63
62
  const _styles = styles;
64
63
  {
65
64
  const styles = _styles.useVariants({
@@ -86,7 +85,7 @@ export function TitleHeader({
86
85
  }), /*#__PURE__*/_jsxs(View, {
87
86
  style: styles.barGroup,
88
87
  children: [/*#__PURE__*/_jsx(HeaderSurface, {
89
- color: gradientColor
88
+ color: bgColor
90
89
  }), /*#__PURE__*/_jsxs(View, {
91
90
  style: styles.bar,
92
91
  children: [leading != null && /*#__PURE__*/_jsx(Toolbar, {
@@ -1 +1 @@
1
- {"version":3,"names":["useCallback","useContext","StyleSheet","useUnistyles","resolveThemeColor","FONT_WEIGHT_VALUE","useHeaderBackground","ScreenContext","Toolbar","HeaderDismissButton","HeaderAccessory","HeaderSurface","isCustomTitle","isTextTitle","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","TitleHeader","title","leadingActions","trailingActions","LeftToolbar","RightToolbar","accessory","accessoryPadding","dismissAction","navigation","onDismiss","titleAlignment","background","bg","theme","screen","colorToken","bgColor","color","leadingContent","undefined","trailingContent","setAccessoryInset","setHeaderAccessoryHeight","handleAccessoryHeightChange","height","isTransparent","gradientColor","_styles","styles","useVariants","leading","children","trailing","View","style","container","safeArea","barGroup","bar","titleContainer","pointerEvents","String","trim","length","Text","padding","onHeightChange","create","runtime","position","top","left","right","zIndex","withinScreen","insets","backgroundColor","uni__dependencies","layout","header","flexDirection","alignItems","paddingHorizontal","x","gap","spacing","justifyContent","variants","center","marginLeft","flex","fontSize","typography","lineHeight","letterSpacing","fontWeight","textAlign"],"sourceRoot":"../../../../../../src","sources":["components/header/variants/TitleHeader/index.tsx"],"mappings":";;;;AAAA,SAAyBA,WAAW,EAAEC,UAAU,QAAQ,OAAO;AAG/D,SAASC,UAAU,EAAEC,YAAY,QAA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a;IAClEC,UAAU,EAAE3F,iBAAiB,CAAC6B,KAAK,CAAC2D,UAAU,CAACL,QAAQ,CAAC,UAAU,CAAC,CAACQ,UAAU,CAAC;IAC/E1D,KAAK,EAAGJ,KAAK,CAACI,KAAK,CAAmD,cAAc,CAAC,IAAI,EAAE;IAC3FkD,QAAQ,EAAE;MACRzD,cAAc,EAAE;QACd0D,MAAM,EAAE;UAAEQ,SAAS,EAAE;QAAS,CAAC;QAC/BzB,IAAI,EAAE;UAAEyB,SAAS,EAAE;QAAO;MAC5B;IACF,CAAC;IAAAnB,iBAAA;EACH;AACF,CAAC,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["useCallback","useContext","StyleSheet","useUnistyles","resolveThemeColor","FONT_WEIGHT_VALUE","useHeaderBackground","ScreenContext","Toolbar","HeaderDismissButton","HeaderAccessory","HeaderSurface","isCustomTitle","isTextTitle","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","TitleHeader","title","leadingActions","trailingActions","LeftToolbar","RightToolbar","accessory","accessoryPadding","dismissAction","navigation","onDismiss","titleAlignment","background","bg","theme","screen","colorToken","bgColor","color","leadingContent","undefined","trailingContent","setAccessoryInset","setHeaderAccessoryHeight","handleAccessoryHeightChange","height","isTransparent","_styles","styles","useVariants","leading","children","trailing","View","style","container","safeArea","barGroup","bar","titleContainer","pointerEvents","String","trim","length","Text","padding","onHeightChange","create","runtime","position","top","left","right","zIndex","withinScreen","insets","backgroundColor","uni__dependencies","layout","header","flexDirection","alignItems","paddingHorizontal","x","gap","spacing","justifyContent","variants","center","marginLeft","flex","fontSize","typography","lineHeight","letterSpacing","fontWeight","textAlign"],"sourceRoot":"../../../../../../src","sources":["components/header/variants/TitleHeader/index.tsx"],"mappings":";;;;AAAA,SAAyBA,WAAW,EAAEC,UAAU,QAAQ,OAAO;AAG/D,SAASC,UAAU,EAAEC,YAAY,QAAQ,wBAAwB;AAGjE,SAASC,iBAAiB;AAC1B,SAASC,iBAAiB;AAC1B,SAASC,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CAAC;IAC/EzD,KAAK,EAAGJ,KAAK,CAACI,KAAK,CAAmD,cAAc,CAAC,IAAI,EAAE;IAC3FiD,QAAQ,EAAE;MACRxD,cAAc,EAAE;QACdyD,MAAM,EAAE;UAAEQ,SAAS,EAAE;QAAS,CAAC;QAC/BzB,IAAI,EAAE;UAAEyB,SAAS,EAAE;QAAO;MAC5B;IACF,CAAC;IAAAnB,iBAAA;EACH;AACF,CAAC,CAAC,CAAC","ignoreList":[]}
@@ -1,12 +1,36 @@
1
- import { type ViewProps } from "react-native";
1
+ import { type ComponentPropsWithRef, type ElementType, type ReactElement } from "react";
2
+ import { View } from "react-native";
2
3
  import { type BoxStyleProps } from "./utils.js";
3
- export interface BoxProps extends ViewProps, BoxStyleProps {
4
- /** Merge Box's style/props onto a single child instead of rendering a View. */
4
+ /** Props owned by Box itself — everything else belongs to the rendered element. */
5
+ interface BoxOwnProps extends BoxStyleProps {
6
+ /** Merge Box's style/props onto a single child instead of rendering an element. Takes precedence over `as`. */
5
7
  asChild?: boolean;
6
8
  }
9
+ /**
10
+ * Props of `Box` when cast as `T`. Token style-props plus everything the
11
+ * rendered component accepts — `<Box as={Pressable} onPress={…} />` type-checks
12
+ * against `Pressable`, not `View`.
13
+ */
14
+ export type BoxProps<T extends ElementType = typeof View> = BoxOwnProps & {
15
+ /** Render as this component instead of `View`. It must accept a `style` prop. */
16
+ as?: T;
17
+ } & Omit<ComponentPropsWithRef<T>, keyof BoxOwnProps | "as">;
7
18
  /**
8
19
  * Base layout primitive: a `View` styled through theme-token props.
9
20
  * The only component family exposing token style-props.
21
+ *
22
+ * Pass `as` to cast it as another component — the token style-props still
23
+ * resolve, and the rest of the props are typed against that component.
24
+ * Note that `as` renders a component Box does not own, so a Unistyles style
25
+ * handed to it only stays theme-reactive if that component's own module runs
26
+ * through the Unistyles Babel plugin (see the stylesheet note below).
27
+ *
28
+ * @example
29
+ * ```tsx
30
+ * <Box row gap="2" p="4" />
31
+ * <Box as={Pressable} onPress={onPress} p="3" radius="md" />
32
+ * ```
10
33
  */
11
- export declare const Box: import("react").ForwardRefExoticComponent<BoxProps & import("react").RefAttributes<import("react-native/types_generated/src/private/webapis/dom/nodes/ReactNativeElement").default>>;
34
+ export declare const Box: <T extends ElementType = typeof View>(props: BoxProps<T>) => ReactElement | null;
35
+ export {};
12
36
  //# sourceMappingURL=Box.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Box.d.ts","sourceRoot":"","sources":["../../../../../src/components/box/Box.tsx"],"names":[],"mappings":"AACA,OAAO,EAAQ,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAKpD,OAAO,EAAuB,KAAK,aAAa,EAAmB,MAAM,YAAS,CAAC;AAEnF,MAAM,WAAW,QAAS,SAAQ,SAAS,EAAE,aAAa;IACxD,+EAA+E;IAC/E,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAID;;;GAGG;AACH,eAAO,MAAM,GAAG,sLA6Bd,CAAC"}
1
+ {"version":3,"file":"Box.d.ts","sourceRoot":"","sources":["../../../../../src/components/box/Box.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,qBAAqB,EAC1B,KAAK,WAAW,EAEhB,KAAK,YAAY,EAElB,MAAM,OAAO,CAAC;AACf,OAAO,EAAkB,IAAI,EAAkB,MAAM,cAAc,CAAC;AAKpE,OAAO,EAAuB,KAAK,aAAa,EAAmB,MAAM,YAAS,CAAC;AAEnF,mFAAmF;AACnF,UAAU,WAAY,SAAQ,aAAa;IACzC,+GAA+G;IAC/G,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED;;;;GAIG;AACH,MAAM,MAAM,QAAQ,CAAC,CAAC,SAAS,WAAW,GAAG,OAAO,IAAI,IAAI,WAAW,GAAG;IACxE,iFAAiF;IACjF,EAAE,CAAC,EAAE,CAAC,CAAC;CACR,GAAG,IAAI,CAAC,qBAAqB,CAAC,CAAC,CAAC,EAAE,MAAM,WAAW,GAAG,IAAI,CAAC,CAAC;AA6C7D;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,GAAG,EAA4B,CAAC,CAAC,SAAS,WAAW,GAAG,OAAO,IAAI,EAC9E,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,KACf,YAAY,GAAG,IAAI,CAAC"}
@@ -1,24 +1,19 @@
1
1
  /**
2
- * How far the overlay extends below the bar's bottom edge, in dp.
3
- *
4
- * The fade needs more room than the bar alone can give it: confined to the bar,
5
- * the curve has to be steep enough to read as a band. Overhanging lets the tail
6
- * finish in open space, so the header releases content instead of cutting it.
2
+ * Opacity at the overlay's bottom edge. The top is fully opaque, so the header
3
+ * thins slightly toward the boundary rather than cutting content off square —
4
+ * but never far enough to read as see-through.
7
5
  */
8
- export declare const HEADER_FADE_EXTENT = 8;
6
+ export declare const HEADER_FADE_END_OPACITY = 0.85;
9
7
  export interface HeaderGradientOverlayProps {
10
- /** Fill color, fading to fully transparent along the overlay. */
8
+ /** Fill color, ramped from opaque to {@link HEADER_FADE_END_OPACITY}. */
11
9
  color: string;
12
10
  }
13
11
  /**
14
- * Vertical fade-out overlay behind header content, shared by header variants.
15
- *
16
- * Reaches zero rather than stopping short. An overlay ending at partial opacity
17
- * leaves a hard step wherever it is clipped, and that step is far more visible
18
- * than the fade it was meant to hide — it is what cuts content off square as it
19
- * scrolls under the header.
12
+ * Vertical fade behind header content, shared by header variants.
20
13
  *
21
- * Callers size it to overhang the bar by {@link HEADER_FADE_EXTENT}.
14
+ * A two-stop linear ramp spanning the overlay's own box: it neither overhangs
15
+ * the surface nor reserves a band inside it, so callers size the surface and
16
+ * the ramp simply spans whatever they gave it.
22
17
  */
23
18
  export declare function HeaderGradientOverlay({ color }: HeaderGradientOverlayProps): import("react").JSX.Element;
24
19
  //# sourceMappingURL=HeaderGradientOverlay.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"HeaderGradientOverlay.d.ts","sourceRoot":"","sources":["../../../../../../src/components/header/parts/HeaderGradientOverlay.tsx"],"names":[],"mappings":"AAIA;;;;;;GAMG;AACH,eAAO,MAAM,kBAAkB,IAAI,CAAC;AAsDpC,MAAM,WAAW,0BAA0B;IACzC,iEAAiE;IACjE,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;;;;;;;;GASG;AACH,wBAAgB,qBAAqB,CAAC,EAAE,KAAK,EAAE,EAAE,0BAA0B,+BAe1E"}
1
+ {"version":3,"file":"HeaderGradientOverlay.d.ts","sourceRoot":"","sources":["../../../../../../src/components/header/parts/HeaderGradientOverlay.tsx"],"names":[],"mappings":"AAIA;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,OAAO,CAAC;AAE5C,MAAM,WAAW,0BAA0B;IACzC,yEAAyE;IACzE,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,EAAE,KAAK,EAAE,EAAE,0BAA0B,+BAc1E"}
@@ -3,20 +3,23 @@ type HeaderOpacityStyle = ReturnType<typeof useAnimatedStyle<{
3
3
  opacity: number;
4
4
  }>>;
5
5
  export interface HeaderSurfaceProps {
6
- /** Fill color, fading to fully transparent along the bottom edge. */
6
+ /** Fill color, ramped toward the surface's bottom edge unless `solid`. */
7
7
  color: string;
8
8
  /** Opacity style for variants that fade the whole surface in as they collapse. */
9
9
  animatedStyle?: HeaderOpacityStyle;
10
10
  /**
11
- * Height of the bottom gradient in dp. The region above it uses a solid fill.
12
- * @defaultValue The themed bar height plus `HEADER_FADE_EXTENT`.
11
+ * Fill flat instead of ramping — for a surface that has to hide content
12
+ * outright, such as a sticky accessory resting over the scroll content.
13
13
  */
14
- fadeHeight?: number;
14
+ solid?: boolean;
15
15
  }
16
16
  /**
17
- * Header background with a solid fill and a bottom gradient.
18
- * A fixed gradient height keeps tall accessories from becoming translucent.
17
+ * Header background covering the bar and any accessory as one surface, so
18
+ * content scrolling under the header meets a single boundary rather than two.
19
+ *
20
+ * The ramp spans the surface itself: it is sized by the caller and stays inside
21
+ * those bounds, so a taller surface stretches the fade rather than adding to it.
19
22
  */
20
- export declare function HeaderSurface({ color, animatedStyle, fadeHeight }: HeaderSurfaceProps): import("react").JSX.Element;
23
+ export declare function HeaderSurface({ color, animatedStyle, solid }: HeaderSurfaceProps): import("react").JSX.Element;
21
24
  export {};
22
25
  //# sourceMappingURL=HeaderSurface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"HeaderSurface.d.ts","sourceRoot":"","sources":["../../../../../../src/components/header/parts/HeaderSurface.tsx"],"names":[],"mappings":"AAEA,OAAiB,EAAE,KAAK,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAK1E,KAAK,kBAAkB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC,CAAC;AAEnF,MAAM,WAAW,kBAAkB;IACjC,qEAAqE;IACrE,KAAK,EAAE,MAAM,CAAC;IACd,kFAAkF;IAClF,aAAa,CAAC,EAAE,kBAAkB,CAAC;IACnC;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,EAAE,KAAK,EAAE,aAAa,EAAE,UAAU,EAAE,EAAE,kBAAkB,+BASrF"}
1
+ {"version":3,"file":"HeaderSurface.d.ts","sourceRoot":"","sources":["../../../../../../src/components/header/parts/HeaderSurface.tsx"],"names":[],"mappings":"AAEA,OAAiB,EAAE,KAAK,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAK1E,KAAK,kBAAkB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC,CAAC;AAEnF,MAAM,WAAW,kBAAkB;IACjC,0EAA0E;IAC1E,KAAK,EAAE,MAAM,CAAC;IACd,kFAAkF;IAClF,aAAa,CAAC,EAAE,kBAAkB,CAAC;IACnC;;;OAGG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,EAAE,KAAK,EAAE,aAAa,EAAE,KAAK,EAAE,EAAE,kBAAkB,+BAMhF"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/header/variants/LargeTitleHeader/index.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,gBAAa,CAAC;AAE3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAgB,CAAC;AASvD,MAAM,WAAW,qBAAsB,SAAQ,gBAAgB;IAC7D,uDAAuD;IACvD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,2DAA2D;IAC3D,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,yEAAyE;IACzE,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B;;;;OAIG;IACH,iBAAiB,CAAC,EAAE,uBAAuB,CAAC;IAC5C;;;OAGG;IACH,cAAc,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;CACpC;AAmED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,cAAc,EACd,eAAe,EACf,WAAW,EACX,YAAY,EACZ,SAAS,EACT,gBAAsB,EACtB,iBAA4B,EAC5B,aAAsB,EACtB,UAAU,EACV,SAAS,EACT,cAAyB,EACzB,kBAA0B,EAC1B,UAAU,EACV,EAAE,GACH,EAAE,qBAAqB,+BA0LvB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/header/variants/LargeTitleHeader/index.tsx"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,gBAAa,CAAC;AAE3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAgB,CAAC;AASvD,MAAM,WAAW,qBAAsB,SAAQ,gBAAgB;IAC7D,uDAAuD;IACvD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,2DAA2D;IAC3D,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,yEAAyE;IACzE,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B;;;;OAIG;IACH,iBAAiB,CAAC,EAAE,uBAAuB,CAAC;IAC5C;;;OAGG;IACH,cAAc,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;CACpC;AAyED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,cAAc,EACd,eAAe,EACf,WAAW,EACX,YAAY,EACZ,SAAS,EACT,gBAAsB,EACtB,iBAA4B,EAC5B,aAAsB,EACtB,UAAU,EACV,SAAS,EACT,cAAyB,EACzB,kBAA0B,EAC1B,UAAU,EACV,EAAE,GACH,EAAE,qBAAqB,+BA0LvB"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/header/variants/TitleHeader/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAA2B,MAAM,OAAO,CAAC;AAKhE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAM/C,OAAO,EAAuB,KAAK,kBAAkB,EAAE,MAAM,yBAAsB,CAAC;AAGpF,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gBAAa,CAAC;AAG1D,MAAM,WAAW,gBAAiB,SAAQ,kBAAkB;IAC1D;;;;OAIG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB;;;OAGG;IACH,cAAc,CAAC,EAAE,SAAS,CAAC;IAC3B,sCAAsC;IACtC,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB;;;OAGG;IACH,eAAe,CAAC,EAAE,SAAS,CAAC;IAC5B,uCAAuC;IACvC,YAAY,CAAC,EAAE,SAAS,CAAC;IACzB;;;;OAIG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,sBAAsB,CAAC;IAC1C,8DAA8D;IAC9D,cAAc,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;IACnC,mGAAmG;IACnG,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,kCAAkC;IAClC,EAAE,CAAC,EAAE,UAAU,CAAC;CACjB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,cAAc,EACd,eAAe,EACf,WAAW,EACX,YAAY,EACZ,SAAS,EACT,gBAAsB,EACtB,aAAsB,EACtB,UAAU,EACV,SAAS,EACT,cAAyB,EACzB,UAAU,EACV,EAAE,GACH,EAAE,gBAAgB,+BAiElB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/header/variants/TitleHeader/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAA2B,MAAM,OAAO,CAAC;AAKhE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAM/C,OAAO,EAAuB,KAAK,kBAAkB,EAAE,MAAM,yBAAsB,CAAC;AAGpF,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gBAAa,CAAC;AAG1D,MAAM,WAAW,gBAAiB,SAAQ,kBAAkB;IAC1D;;;;OAIG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB;;;OAGG;IACH,cAAc,CAAC,EAAE,SAAS,CAAC;IAC3B,sCAAsC;IACtC,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB;;;OAGG;IACH,eAAe,CAAC,EAAE,SAAS,CAAC;IAC5B,uCAAuC;IACvC,YAAY,CAAC,EAAE,SAAS,CAAC;IACzB;;;;OAIG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,sBAAsB,CAAC;IAC1C,8DAA8D;IAC9D,cAAc,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;IACnC,mGAAmG;IACnG,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,kCAAkC;IAClC,EAAE,CAAC,EAAE,UAAU,CAAC;CACjB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,cAAc,EACd,eAAe,EACf,WAAW,EACX,YAAY,EACZ,SAAS,EACT,gBAAsB,EACtB,aAAsB,EACtB,UAAU,EACV,SAAS,EACT,cAAyB,EACzB,UAAU,EACV,EAAE,GACH,EAAE,gBAAgB,+BA8DlB"}
@@ -34,5 +34,5 @@ export interface SurfaceProps extends Omit<BoxProps, "background"> {
34
34
  * </Surface>
35
35
  * ```
36
36
  */
37
- export declare const Surface: import("react").ForwardRefExoticComponent<SurfaceProps & import("react").RefAttributes<import("react-native/types_generated/src/private/webapis/dom/nodes/ReactNativeElement").default>>;
37
+ export declare const Surface: import("react").ForwardRefExoticComponent<Omit<SurfaceProps, "ref"> & import("react").RefAttributes<import("react-native/types_generated/src/private/webapis/dom/nodes/ReactNativeElement").default>>;
38
38
  //# sourceMappingURL=Surface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Surface.d.ts","sourceRoot":"","sources":["../../../../../src/components/surface/Surface.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAc,YAAY,EAAE,MAAM,cAAc,CAAC;AAC7D,OAAO,EAA8B,KAAK,QAAQ,EAAE,MAAM,iBAAQ,CAAC;AAEnE,6CAA6C;AAC7C,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,QAAQ,GAAG,QAAQ,GAAG,aAAa,CAAC;AAE1E,MAAM,WAAW,YAAa,SAAQ,IAAI,CAAC,QAAQ,EAAE,YAAY,CAAC;IAChE,sDAAsD;IACtD,OAAO,CAAC,EAAE,cAAc,CAAC;IACzB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,YAAY,CAAC;CAC1B;AA6BD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,OAAO,0LAiBlB,CAAC"}
1
+ {"version":3,"file":"Surface.d.ts","sourceRoot":"","sources":["../../../../../src/components/surface/Surface.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAc,YAAY,EAAE,MAAM,cAAc,CAAC;AAC7D,OAAO,EAA8B,KAAK,QAAQ,EAAE,MAAM,iBAAQ,CAAC;AAEnE,6CAA6C;AAC7C,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,QAAQ,GAAG,QAAQ,GAAG,aAAa,CAAC;AAE1E,MAAM,WAAW,YAAa,SAAQ,IAAI,CAAC,QAAQ,EAAE,YAAY,CAAC;IAChE,sDAAsD;IACtD,OAAO,CAAC,EAAE,cAAc,CAAC;IACzB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,YAAY,CAAC;CAC1B;AA6BD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,OAAO,uMAiBlB,CAAC"}
@@ -22,7 +22,7 @@ export interface ToastProps extends Omit<SurfaceProps, "id" | "variant"> {
22
22
  /** Local close callback used by `Toast.Close`. */
23
23
  onClose?: () => void;
24
24
  }
25
- declare const ToastRoot: import("react").ForwardRefExoticComponent<ToastProps & import("react").RefAttributes<import("react-native/types_generated/src/private/webapis/dom/nodes/ReactNativeElement").default>>;
25
+ declare const ToastRoot: import("react").ForwardRefExoticComponent<Omit<ToastProps, "ref"> & import("react").RefAttributes<import("react-native/types_generated/src/private/webapis/dom/nodes/ReactNativeElement").default>>;
26
26
  export interface ToastTitleProps extends TextProps {
27
27
  }
28
28
  declare const ToastTitle: import("react").ForwardRefExoticComponent<ToastTitleProps & import("react").RefAttributes<import("react-native/types_generated/src/private/webapis/dom/nodes/ReactNativeElement").default>>;
@@ -1 +1 @@
1
- {"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../../../../src/components/toast/Toast.tsx"],"names":[],"mappings":"AAAA,OAAO,EAIL,KAAK,SAAS,EAIf,MAAM,OAAO,CAAC;AACf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- "version": "0.11.9",
3
+ "version": "0.11.11",
4
4
  "description": "Themeable React Native UI components built on react-native-unistyles",
5
5
  "main": "./lib/module/index.js",
6
6
  "types": "./lib/typescript/src/index.d.ts",
@@ -1,53 +1,96 @@
1
- import { type ComponentRef, forwardRef } from "react";
2
- import { View, type ViewProps } from "react-native";
1
+ import {
2
+ type ComponentPropsWithRef,
3
+ type ElementType,
4
+ forwardRef,
5
+ type ReactElement,
6
+ type ReactNode,
7
+ } from "react";
8
+ import { type StyleProp, View, type ViewStyle } from "react-native";
3
9
 
4
10
  import { StyleSheet, useUnistyles } from "react-native-unistyles";
5
11
 
6
12
  import { Slot } from "../slot";
7
13
  import { BOX_STYLE_PROP_KEYS, type BoxStyleProps, resolveBoxStyle } from "./utils";
8
14
 
9
- export interface BoxProps extends ViewProps, BoxStyleProps {
10
- /** Merge Box's style/props onto a single child instead of rendering a View. */
15
+ /** Props owned by Box itself — everything else belongs to the rendered element. */
16
+ interface BoxOwnProps extends BoxStyleProps {
17
+ /** Merge Box's style/props onto a single child instead of rendering an element. Takes precedence over `as`. */
11
18
  asChild?: boolean;
12
19
  }
13
20
 
14
- const STYLE_KEYS = new Set<string>(BOX_STYLE_PROP_KEYS as readonly string[]);
15
-
16
21
  /**
17
- * Base layout primitive: a `View` styled through theme-token props.
18
- * The only component family exposing token style-props.
22
+ * Props of `Box` when cast as `T`. Token style-props plus everything the
23
+ * rendered component accepts — `<Box as={Pressable} onPress={…} />` type-checks
24
+ * against `Pressable`, not `View`.
19
25
  */
20
- export const Box = forwardRef<ComponentRef<typeof View>, BoxProps>(function Box(
21
- { asChild, style, children, ...rest },
26
+ export type BoxProps<T extends ElementType = typeof View> = BoxOwnProps & {
27
+ /** Render as this component instead of `View`. It must accept a `style` prop. */
28
+ as?: T;
29
+ } & Omit<ComponentPropsWithRef<T>, keyof BoxOwnProps | "as">;
30
+
31
+ /** Erased prop shape the implementation works with — the generic lives on the exported cast. */
32
+ interface BoxRenderProps extends BoxOwnProps {
33
+ as?: ElementType;
34
+ style?: StyleProp<ViewStyle>;
35
+ children?: ReactNode;
36
+ [key: string]: unknown;
37
+ }
38
+
39
+ const STYLE_KEYS = new Set<string>(BOX_STYLE_PROP_KEYS as readonly string[]);
40
+
41
+ const BoxWithRef = forwardRef<unknown, BoxRenderProps>(function Box(
42
+ { as, asChild, style, children, ...rest }: BoxRenderProps,
22
43
  ref
23
44
  ) {
24
45
  const { theme } = useUnistyles();
25
46
 
26
47
  const styleProps: Record<string, unknown> = {};
27
- const viewProps: Record<string, unknown> = {};
48
+ const elementProps: Record<string, unknown> = {};
28
49
  for (const key of Object.keys(rest)) {
29
- const value = (rest as Record<string, unknown>)[key];
50
+ const value = rest[key];
30
51
  if (STYLE_KEYS.has(key)) styleProps[key] = value;
31
- else viewProps[key] = value;
52
+ else elementProps[key] = value;
32
53
  }
33
54
 
34
55
  const mergedStyle = [styles.root, resolveBoxStyle(styleProps as BoxStyleProps, theme), style];
35
56
 
36
57
  if (asChild) {
37
58
  return (
38
- <Slot ownerName="Box" slotProps={{ ...viewProps, style: mergedStyle, ref }}>
59
+ <Slot ownerName="Box" slotProps={{ ...elementProps, style: mergedStyle, ref }}>
39
60
  {children}
40
61
  </Slot>
41
62
  );
42
63
  }
43
64
 
65
+ const Component = (as ?? View) as ElementType;
66
+
44
67
  return (
45
- <View ref={ref} style={mergedStyle} {...(viewProps as ViewProps)}>
68
+ <Component ref={ref} style={mergedStyle} {...elementProps}>
46
69
  {children}
47
- </View>
70
+ </Component>
48
71
  );
49
72
  });
50
73
 
74
+ /**
75
+ * Base layout primitive: a `View` styled through theme-token props.
76
+ * The only component family exposing token style-props.
77
+ *
78
+ * Pass `as` to cast it as another component — the token style-props still
79
+ * resolve, and the rest of the props are typed against that component.
80
+ * Note that `as` renders a component Box does not own, so a Unistyles style
81
+ * handed to it only stays theme-reactive if that component's own module runs
82
+ * through the Unistyles Babel plugin (see the stylesheet note below).
83
+ *
84
+ * @example
85
+ * ```tsx
86
+ * <Box row gap="2" p="4" />
87
+ * <Box as={Pressable} onPress={onPress} p="3" radius="md" />
88
+ * ```
89
+ */
90
+ export const Box = BoxWithRef as unknown as <T extends ElementType = typeof View>(
91
+ props: BoxProps<T>
92
+ ) => ReactElement | null;
93
+
51
94
  // ─── Styles ───────────────────────────────────────────────────────────────────
52
95
  //
53
96
  // Box has no static style of its own — this stylesheet exists so the
@@ -3,80 +3,23 @@ import { useId } from "react";
3
3
  import Svg, { Defs, Rect, Stop, LinearGradient as SvgLinearGradient } from "react-native-svg";
4
4
 
5
5
  /**
6
- * How far the overlay extends below the bar's bottom edge, in dp.
7
- *
8
- * The fade needs more room than the bar alone can give it: confined to the bar,
9
- * the curve has to be steep enough to read as a band. Overhanging lets the tail
10
- * finish in open space, so the header releases content instead of cutting it.
11
- */
12
- export const HEADER_FADE_EXTENT = 8;
13
-
14
- /**
15
- * Where the fade begins, as a fraction of the overlay's height — the bar plus
16
- * {@link HEADER_FADE_EXTENT}.
17
- *
18
- * Sits inside the bar rather than at its bottom edge, so the tint has already
19
- * begun thinning before content reaches the boundary. That is the trade this
20
- * value makes: a longer, gentler ramp, paid for with content being faintly
21
- * visible through the lower part of the bar.
6
+ * Opacity at the overlay's bottom edge. The top is fully opaque, so the header
7
+ * thins slightly toward the boundary rather than cutting content off square —
8
+ * but never far enough to read as see-through.
22
9
  */
23
- const FADE_START = 0.5;
24
-
25
- /**
26
- * Stops used to approximate the fade curve. Below ~10 the ramp shows as a series
27
- * of bands on an 8-bit display; above ~14 the extra stops cost SVG parse time
28
- * with nothing visible in return.
29
- */
30
- const FADE_STOPS = 4;
31
-
32
- /** Ceiling on the fade's opacity — see {@link alphaAt}. */
33
- const MAX_FADE_ALPHA = 0.65;
34
-
35
- /**
36
- * Raised cosine, capped at {@link MAX_FADE_ALPHA}, reaching 0 at the overlay's
37
- * bottom.
38
- *
39
- * The curve's slope is zero at both ends, so neither the start of the fade nor
40
- * its finish leaves a seam. A two-stop linear ramp has a constant slope that
41
- * begins and ends abruptly, and those two hard edges are what read as a line
42
- * drawn across the content rather than the header letting go of it.
43
- *
44
- * The cap holds the ramp just short of solid, so the whole overlay reads as one
45
- * continuous gradient rather than an opaque plateau with a curve bolted on.
46
- */
47
- const alphaAt = (t: number) => (1 + Math.cos(Math.PI * t) * MAX_FADE_ALPHA) / 2;
48
-
49
- /**
50
- * Every input is a module constant, so the ramp is built once at load rather
51
- * than rebuilt per render.
52
- *
53
- * The leading stop belongs to this list rather than being a sibling element:
54
- * `LinearGradient` types its children as a flat `ReactElement[]`, so an element
55
- * beside a mapped array would nest and fail to type-check.
56
- */
57
- const STOPS = [
58
- { offset: 0, opacity: 1 },
59
- ...Array.from({ length: FADE_STOPS }, (_, index) => {
60
- const t = index / (FADE_STOPS - 1);
61
- const offset = FADE_START + t * (1 - FADE_START);
62
- return { offset, opacity: offset === 1 ? 0 : alphaAt(t) };
63
- }),
64
- ];
10
+ export const HEADER_FADE_END_OPACITY = 0.85;
65
11
 
66
12
  export interface HeaderGradientOverlayProps {
67
- /** Fill color, fading to fully transparent along the overlay. */
13
+ /** Fill color, ramped from opaque to {@link HEADER_FADE_END_OPACITY}. */
68
14
  color: string;
69
15
  }
70
16
 
71
17
  /**
72
- * Vertical fade-out overlay behind header content, shared by header variants.
73
- *
74
- * Reaches zero rather than stopping short. An overlay ending at partial opacity
75
- * leaves a hard step wherever it is clipped, and that step is far more visible
76
- * than the fade it was meant to hide — it is what cuts content off square as it
77
- * scrolls under the header.
18
+ * Vertical fade behind header content, shared by header variants.
78
19
  *
79
- * Callers size it to overhang the bar by {@link HEADER_FADE_EXTENT}.
20
+ * A two-stop linear ramp spanning the overlay's own box: it neither overhangs
21
+ * the surface nor reserves a band inside it, so callers size the surface and
22
+ * the ramp simply spans whatever they gave it.
80
23
  */
81
24
  export function HeaderGradientOverlay({ color }: HeaderGradientOverlayProps) {
82
25
  const gradientId = useId();
@@ -85,9 +28,8 @@ export function HeaderGradientOverlay({ color }: HeaderGradientOverlayProps) {
85
28
  <Svg height="100%" width="100%">
86
29
  <Defs>
87
30
  <SvgLinearGradient id={gradientId} x1="0" y1="0" x2="0" y2="1">
88
- {STOPS.map((stop) => (
89
- <Stop key={stop.offset} offset={stop.offset} stopColor={color} stopOpacity={stop.opacity} />
90
- ))}
31
+ <Stop offset={0} stopColor={color} stopOpacity={1} />
32
+ <Stop offset={1} stopColor={color} stopOpacity={HEADER_FADE_END_OPACITY} />
91
33
  </SvgLinearGradient>
92
34
  </Defs>
93
35
  <Rect width="100%" height="100%" fill={`url(#${gradientId})`} />
@@ -3,60 +3,47 @@ import { View } from "react-native";
3
3
  import Animated, { type useAnimatedStyle } from "react-native-reanimated";
4
4
  import { StyleSheet } from "react-native-unistyles";
5
5
 
6
- import { HEADER_FADE_EXTENT, HeaderGradientOverlay } from "./HeaderGradientOverlay";
6
+ import { HeaderGradientOverlay } from "./HeaderGradientOverlay";
7
7
 
8
8
  type HeaderOpacityStyle = ReturnType<typeof useAnimatedStyle<{ opacity: number }>>;
9
9
 
10
10
  export interface HeaderSurfaceProps {
11
- /** Fill color, fading to fully transparent along the bottom edge. */
11
+ /** Fill color, ramped toward the surface's bottom edge unless `solid`. */
12
12
  color: string;
13
13
  /** Opacity style for variants that fade the whole surface in as they collapse. */
14
14
  animatedStyle?: HeaderOpacityStyle;
15
15
  /**
16
- * Height of the bottom gradient in dp. The region above it uses a solid fill.
17
- * @defaultValue The themed bar height plus `HEADER_FADE_EXTENT`.
16
+ * Fill flat instead of ramping — for a surface that has to hide content
17
+ * outright, such as a sticky accessory resting over the scroll content.
18
18
  */
19
- fadeHeight?: number;
19
+ solid?: boolean;
20
20
  }
21
21
 
22
22
  /**
23
- * Header background with a solid fill and a bottom gradient.
24
- * A fixed gradient height keeps tall accessories from becoming translucent.
23
+ * Header background covering the bar and any accessory as one surface, so
24
+ * content scrolling under the header meets a single boundary rather than two.
25
+ *
26
+ * The ramp spans the surface itself: it is sized by the caller and stays inside
27
+ * those bounds, so a taller surface stretches the fade rather than adding to it.
25
28
  */
26
- export function HeaderSurface({ color, animatedStyle, fadeHeight }: HeaderSurfaceProps) {
29
+ export function HeaderSurface({ color, animatedStyle, solid }: HeaderSurfaceProps) {
27
30
  return (
28
31
  <Animated.View style={[styles.surface, animatedStyle]} pointerEvents="none">
29
- <View style={styles.fill(color, fadeHeight)} />
30
- <View style={styles.fade(fadeHeight)}>
31
- <HeaderGradientOverlay color={color} />
32
- </View>
32
+ {solid ? <View style={styles.fill(color)} /> : <HeaderGradientOverlay color={color} />}
33
33
  </Animated.View>
34
34
  );
35
35
  }
36
36
 
37
- const styles = StyleSheet.create((theme) => ({
38
- // Extend the fade below the header's layout bounds.
37
+ const styles = StyleSheet.create(() => ({
39
38
  surface: {
40
39
  position: "absolute",
41
40
  top: 0,
42
41
  left: 0,
43
42
  right: 0,
44
- bottom: -HEADER_FADE_EXTENT,
43
+ bottom: 0,
45
44
  },
46
- // Fill the region above the gradient.
47
- fill: (color: string, fadeHeight: number | undefined) => ({
48
- position: "absolute",
49
- top: 0,
50
- left: 0,
51
- right: 0,
52
- bottom: fadeHeight ?? theme.layout.header.height + HEADER_FADE_EXTENT,
45
+ fill: (color: string) => ({
46
+ flex: 1,
53
47
  backgroundColor: color,
54
48
  }),
55
- fade: (fadeHeight: number | undefined) => ({
56
- position: "absolute",
57
- left: 0,
58
- right: 0,
59
- bottom: 0,
60
- height: fadeHeight ?? theme.layout.header.height + HEADER_FADE_EXTENT,
61
- }),
62
49
  }));
@@ -12,7 +12,6 @@ import { SCREEN_HEADER_PORTAL_HOST, useScreen } from "../../../screen/ScreenCont
12
12
  import { Toolbar } from "../../../toolbar";
13
13
  import { HeaderDismissButton } from "../../header-buttons";
14
14
  import { HeaderAccessory, HeaderAccessorySpacer } from "../../parts/HeaderAccessory";
15
- import { HEADER_FADE_EXTENT } from "../../parts/HeaderGradientOverlay";
16
15
  import { HeaderSurface } from "../../parts/HeaderSurface";
17
16
  import type { HeaderAccessoryBehavior } from "../../types";
18
17
  import { isCustomTitle, isTextTitle } from "../../utils";
@@ -49,8 +48,11 @@ function LargeTitlePortalContent({
49
48
  title,
50
49
  overline,
51
50
  subtitle,
51
+ hasAccessoryBelow,
52
52
  onHeightChange,
53
53
  }: Pick<LargeTitleHeaderProps, "title" | "overline" | "subtitle"> & {
54
+ /** Reserve a gap before a sticky accessory below this block. */
55
+ hasAccessoryBelow: boolean;
54
56
  /** Reports the large-title block's layout height in dp. */
55
57
  onHeightChange?: (height: number) => void;
56
58
  }) {
@@ -79,7 +81,10 @@ function LargeTitlePortalContent({
79
81
  const handleLayout = (event: LayoutChangeEvent) => onHeightChange?.(event.nativeEvent.layout.height);
80
82
 
81
83
  return (
82
- <Animated.View style={[styles.portalContent, largeTitleAnimatedStyle]} onLayout={handleLayout}>
84
+ <Animated.View
85
+ style={[styles.portalContent(hasAccessoryBelow), largeTitleAnimatedStyle]}
86
+ onLayout={handleLayout}
87
+ >
83
88
  {!!overline && (
84
89
  <Text
85
90
  style={styles.overline}
@@ -159,7 +164,6 @@ export function LargeTitleHeader({
159
164
  const leadingContent = leadingActions !== undefined ? leadingActions : LeftToolbar;
160
165
  const trailingContent = trailingActions !== undefined ? trailingActions : RightToolbar;
161
166
 
162
- const gradientColor = bgColor;
163
167
  const isSticky = accessoryBehavior === "sticky" && !isLargeTitleHidden;
164
168
  const hasStickyAccessory = isSticky && accessory != null;
165
169
  // Sticky accessories reserve space below the large title; pinned ones add top padding.
@@ -208,8 +212,8 @@ export function LargeTitleHeader({
208
212
  stickyAccessoryOffset > 0 ? interpolate(scrollY.value, [0, stickyAccessoryOffset], [1, 0], "clamp") : 0,
209
213
  }));
210
214
 
211
- // Animate the gradient overlay's opacity: 0 (expanded) → 1 (collapsed).
212
- const gradientOpacityStyle = useAnimatedStyle(() => {
215
+ // Animate the header surface's opacity: 0 (expanded) → 1 (collapsed).
216
+ const surfaceOpacityStyle = useAnimatedStyle(() => {
213
217
  if (isLargeTitleHiddenValue.value) {
214
218
  return { opacity: 1 };
215
219
  }
@@ -222,7 +226,7 @@ export function LargeTitleHeader({
222
226
  };
223
227
  });
224
228
 
225
- useHeaderBackground(bgColor, gradientOpacityStyle);
229
+ useHeaderBackground(bgColor, surfaceOpacityStyle);
226
230
 
227
231
  const compactTitleAnimatedStyle = useAnimatedStyle(() => {
228
232
  if (isLargeTitleHiddenValue.value) {
@@ -280,6 +284,7 @@ export function LargeTitleHeader({
280
284
  title={title}
281
285
  overline={overline}
282
286
  subtitle={subtitle}
287
+ hasAccessoryBelow={hasStickyAccessory}
283
288
  onHeightChange={isSticky ? handleLargeTitleHeightChange : undefined}
284
289
  />
285
290
  {/* Reserve space for the accessory rendered in the overlay. */}
@@ -288,12 +293,12 @@ export function LargeTitleHeader({
288
293
  )}
289
294
  {hasStickyAccessory && (
290
295
  <Animated.View style={[styles.stickySurface, stickySurfaceStyle]} pointerEvents="none">
291
- <HeaderSurface color={gradientColor} animatedStyle={gradientOpacityStyle} />
296
+ <HeaderSurface color={bgColor} animatedStyle={surfaceOpacityStyle} />
292
297
  </Animated.View>
293
298
  )}
294
299
  {/* Share a background between the bar and a pinned accessory. */}
295
300
  <View style={styles.barGroup}>
296
- {!hasStickyAccessory && <HeaderSurface color={gradientColor} animatedStyle={gradientOpacityStyle} />}
301
+ {!hasStickyAccessory && <HeaderSurface color={bgColor} animatedStyle={surfaceOpacityStyle} />}
297
302
  <View style={styles.bar}>
298
303
  {leading != null && <Toolbar>{leading}</Toolbar>}
299
304
  {/* Text can never be the touch target, but custom content may be, so its
@@ -326,7 +331,7 @@ export function LargeTitleHeader({
326
331
  <HeaderSurface
327
332
  color={screenBackground ?? theme.color["surface.canvas"]}
328
333
  animatedStyle={accessorySurfaceStyle}
329
- fadeHeight={HEADER_FADE_EXTENT}
334
+ solid
330
335
  />
331
336
  <HeaderAccessory padding={accessoryPadding} onHeightChange={handleAccessoryHeightChange}>
332
337
  {accessory}
@@ -372,12 +377,12 @@ const styles = StyleSheet.create((theme) => ({
372
377
  },
373
378
  },
374
379
  },
375
- portalContent: {
380
+ portalContent: (hasAccessoryBelow: boolean) => ({
376
381
  gap: 2,
377
- minHeight: theme.layout.header.height,
378
- paddingBottom: theme.spacing["1"],
382
+ // Include the gap in the measured height used to position the accessory.
383
+ paddingBottom: hasAccessoryBelow ? theme.spacing["2"] : 0,
379
384
  paddingHorizontal: theme.layout.screen.padding.x,
380
- },
385
+ }),
381
386
  overline: {
382
387
  fontSize: theme.typography.variants["label-sm"].fontSize,
383
388
  lineHeight: theme.typography.variants["label-sm"].lineHeight,
@@ -94,7 +94,6 @@ export function TitleHeader({
94
94
  const colorToken = background ?? bg;
95
95
  const bgColor =
96
96
  (colorToken ? resolveThemeColor(colorToken, theme) : screen?.background) ?? theme.color["surface.canvas"];
97
- useHeaderBackground(bgColor);
98
97
  const leadingContent = leadingActions !== undefined ? leadingActions : LeftToolbar;
99
98
  const trailingContent = trailingActions !== undefined ? trailingActions : RightToolbar;
100
99
  const setAccessoryInset = screen?.setHeaderAccessoryHeight;
@@ -104,7 +103,7 @@ export function TitleHeader({
104
103
  [setAccessoryInset]
105
104
  );
106
105
  const isTransparent = bgColor === "transparent";
107
- const gradientColor = bgColor;
106
+ useHeaderBackground(bgColor);
108
107
  styles.useVariants({ titleAlignment });
109
108
 
110
109
  const leading =
@@ -129,10 +128,8 @@ export function TitleHeader({
129
128
  return (
130
129
  <View style={styles.container}>
131
130
  <View style={styles.safeArea(isTransparent, bgColor, screen !== null)} />
132
- {/* The fade covers the bar and any accessory as one surface, so content
133
- scrolling under the header meets a single boundary rather than two. */}
134
131
  <View style={styles.barGroup}>
135
- <HeaderSurface color={gradientColor} />
132
+ <HeaderSurface color={bgColor} />
136
133
  <View style={styles.bar}>
137
134
  {leading != null && <Toolbar>{leading}</Toolbar>}
138
135
  {/* Text can never be the touch target, but custom content may be, so its