react-native-terra-ui 0.11.10 → 0.11.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +17 -0
- package/lib/module/components/box/Box.js +35 -10
- package/lib/module/components/box/Box.js.map +1 -1
- package/lib/module/components/header/hooks/use-header-color.js +16 -0
- package/lib/module/components/header/hooks/use-header-color.js.map +1 -0
- package/lib/module/components/header/hooks/use-large-title-header.js +81 -0
- package/lib/module/components/header/hooks/use-large-title-header.js.map +1 -0
- package/lib/module/components/header/parts/HeaderAccessory.js +21 -6
- package/lib/module/components/header/parts/HeaderAccessory.js.map +1 -1
- package/lib/module/components/header/parts/HeaderBar.js +122 -0
- package/lib/module/components/header/parts/HeaderBar.js.map +1 -0
- package/lib/module/components/header/parts/HeaderGradientOverlay.js +20 -76
- package/lib/module/components/header/parts/HeaderGradientOverlay.js.map +1 -1
- package/lib/module/components/header/parts/HeaderSurface.js +16 -37
- package/lib/module/components/header/parts/HeaderSurface.js.map +1 -1
- package/lib/module/components/header/variants/LargeTitleHeader/index.js +51 -388
- package/lib/module/components/header/variants/LargeTitleHeader/index.js.map +1 -1
- package/lib/module/components/header/variants/LargeTitleHeader/parts/LargeTitleContent.js +72 -0
- package/lib/module/components/header/variants/LargeTitleHeader/parts/LargeTitleContent.js.map +1 -0
- package/lib/module/components/header/variants/TitleHeader/index.js +32 -161
- package/lib/module/components/header/variants/TitleHeader/index.js.map +1 -1
- package/lib/module/components/surface/Surface.js +2 -0
- package/lib/module/components/surface/Surface.js.map +1 -1
- package/lib/typescript/src/components/box/Box.d.ts +28 -4
- package/lib/typescript/src/components/box/Box.d.ts.map +1 -1
- package/lib/typescript/src/components/header/hooks/use-header-color.d.ts +4 -0
- package/lib/typescript/src/components/header/hooks/use-header-color.d.ts.map +1 -0
- package/lib/typescript/src/components/header/hooks/use-large-title-header.d.ts +36 -0
- package/lib/typescript/src/components/header/hooks/use-large-title-header.d.ts.map +1 -0
- package/lib/typescript/src/components/header/parts/HeaderAccessory.d.ts +8 -5
- package/lib/typescript/src/components/header/parts/HeaderAccessory.d.ts.map +1 -1
- package/lib/typescript/src/components/header/parts/HeaderBar.d.ts +17 -0
- package/lib/typescript/src/components/header/parts/HeaderBar.d.ts.map +1 -0
- package/lib/typescript/src/components/header/parts/HeaderGradientOverlay.d.ts +12 -15
- package/lib/typescript/src/components/header/parts/HeaderGradientOverlay.d.ts.map +1 -1
- package/lib/typescript/src/components/header/parts/HeaderSurface.d.ts +8 -9
- package/lib/typescript/src/components/header/parts/HeaderSurface.d.ts.map +1 -1
- package/lib/typescript/src/components/header/variants/LargeTitleHeader/index.d.ts +3 -23
- package/lib/typescript/src/components/header/variants/LargeTitleHeader/index.d.ts.map +1 -1
- package/lib/typescript/src/components/header/variants/LargeTitleHeader/parts/LargeTitleContent.d.ts +11 -0
- package/lib/typescript/src/components/header/variants/LargeTitleHeader/parts/LargeTitleContent.d.ts.map +1 -0
- package/lib/typescript/src/components/header/variants/TitleHeader/index.d.ts +3 -19
- package/lib/typescript/src/components/header/variants/TitleHeader/index.d.ts.map +1 -1
- package/lib/typescript/src/components/surface/Surface.d.ts +1 -1
- package/lib/typescript/src/components/surface/Surface.d.ts.map +1 -1
- package/lib/typescript/src/components/toast/Toast.d.ts +1 -1
- package/lib/typescript/src/components/toast/Toast.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/components/box/Box.tsx +59 -16
- package/src/components/header/hooks/use-header-color.ts +14 -0
- package/src/components/header/hooks/use-large-title-header.ts +78 -0
- package/src/components/header/parts/HeaderAccessory.tsx +26 -7
- package/src/components/header/parts/HeaderBar.tsx +125 -0
- package/src/components/header/parts/HeaderGradientOverlay.tsx +18 -70
- package/src/components/header/parts/HeaderSurface.tsx +16 -35
- package/src/components/header/variants/LargeTitleHeader/index.tsx +44 -371
- package/src/components/header/variants/LargeTitleHeader/parts/LargeTitleContent.tsx +88 -0
- package/src/components/header/variants/TitleHeader/index.tsx +32 -149
- package/src/components/surface/Surface.tsx +2 -1
|
@@ -1,58 +1,37 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
import { View } from "react-native-unistyles/components/native/View";
|
|
4
3
|
import Animated from "react-native-reanimated";
|
|
5
4
|
import { StyleSheet } from "react-native-unistyles";
|
|
6
|
-
import {
|
|
7
|
-
import { jsx as _jsx
|
|
5
|
+
import { HEADER_FADE_END_OPACITY, HeaderGradientOverlay } from "./HeaderGradientOverlay.js";
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
8
7
|
/**
|
|
9
|
-
* Header background with
|
|
10
|
-
*
|
|
8
|
+
* Header background with matching gradient boundaries for the bar and accessory.
|
|
9
|
+
*
|
|
10
|
+
* The ramp spans the surface itself: it is sized by the caller and stays inside
|
|
11
|
+
* those bounds, so a taller surface stretches the fade rather than adding to it.
|
|
11
12
|
*/
|
|
12
13
|
export function HeaderSurface({
|
|
13
14
|
color,
|
|
14
15
|
animatedStyle,
|
|
15
|
-
|
|
16
|
+
accessory
|
|
16
17
|
}) {
|
|
17
|
-
return /*#__PURE__*/
|
|
18
|
+
return /*#__PURE__*/_jsx(Animated.View, {
|
|
18
19
|
style: [styles.surface, animatedStyle],
|
|
19
20
|
pointerEvents: "none",
|
|
20
|
-
children:
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
color: color
|
|
26
|
-
})
|
|
27
|
-
})]
|
|
21
|
+
children: /*#__PURE__*/_jsx(HeaderGradientOverlay, {
|
|
22
|
+
color: color,
|
|
23
|
+
startOpacity: accessory ? HEADER_FADE_END_OPACITY : 1,
|
|
24
|
+
endOpacity: accessory ? 0.8 : HEADER_FADE_END_OPACITY
|
|
25
|
+
})
|
|
28
26
|
});
|
|
29
27
|
}
|
|
30
|
-
const styles = StyleSheet.create(
|
|
31
|
-
// Extend the fade below the header's layout bounds.
|
|
28
|
+
const styles = StyleSheet.create(() => ({
|
|
32
29
|
surface: {
|
|
33
30
|
position: "absolute",
|
|
34
31
|
top: 0,
|
|
35
32
|
left: 0,
|
|
36
33
|
right: 0,
|
|
37
|
-
bottom:
|
|
38
|
-
}
|
|
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]
|
|
56
|
-
})
|
|
34
|
+
bottom: 0
|
|
35
|
+
}
|
|
57
36
|
}));
|
|
58
37
|
//# sourceMappingURL=HeaderSurface.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Animated","StyleSheet","
|
|
1
|
+
{"version":3,"names":["Animated","StyleSheet","HEADER_FADE_END_OPACITY","HeaderGradientOverlay","jsx","_jsx","HeaderSurface","color","animatedStyle","accessory","View","style","styles","surface","pointerEvents","children","startOpacity","endOpacity","create","position","top","left","right","bottom"],"sourceRoot":"../../../../../src","sources":["components/header/parts/HeaderSurface.tsx"],"mappings":";;AAAA,OAAOA,QAAQ,MAAiC,yBAAyB;AACzE,SAASC,UAAU,QAAQ,wBAAwB;AAEnD,SAASC,uBAAuB,EAAEC,qBAAqB;AAAkC,SAAAC,GAAA,IAAAC,IAAA;AAazF;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,aAAaA,CAAC;EAAEC,KAAK;EAAEC,aAAa;EAAEC;AAA8B,CAAC,EAAE;EACrF,oBACEJ,IAAA,CAACL,QAAQ,CAACU,IAAI;IAACC,KAAK,EAAE,CAACC,MAAM,CAACC,OAAO,EAAEL,aAAa,CAAE;IAACM,aAAa,EAAC,MAAM;IAAAC,QAAA,eACzEV,IAAA,CAACF,qBAAqB;MACpBI,KAAK,EAAEA,KAAM;MACbS,YAAY,EAAEP,SAAS,GAAGP,uBAAuB,GAAG,CAAE;MACtDe,UAAU,EAAER,SAAS,GAAG,GAAG,GAAGP;IAAwB,CACvD;EAAC,CACW,CAAC;AAEpB;AAEA,MAAMU,MAAM,GAAGX,UAAU,CAACiB,MAAM,CAAC,OAAO;EACtCL,OAAO,EAAE;IACPM,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE,CAAC;IACNC,IAAI,EAAE,CAAC;IACPC,KAAK,EAAE,CAAC;IACRC,MAAM,EAAE;EACV;AACF,CAAC,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1,102 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
import { View } from "react-native-unistyles/components/native/View";
|
|
4
|
-
import {
|
|
5
|
-
import { useCallback, useEffect, useState } from "react";
|
|
6
|
-
import Animated, { interpolate, useAnimatedStyle, useSharedValue } from "react-native-reanimated";
|
|
7
|
-
import { StyleSheet, useUnistyles } from "react-native-unistyles";
|
|
8
|
-
import { resolveThemeColor } from "../../../../utils/resolve-theme-color.js";
|
|
9
|
-
import { FONT_WEIGHT_VALUE } from "../../../../utils/typography.js";
|
|
4
|
+
import { StyleSheet } from "react-native-unistyles";
|
|
10
5
|
import { Portal } from "../../../portal/index.js";
|
|
11
6
|
import { useHeaderBackground } from "../../../screen/parts/ScreenHeaderAppearance.js";
|
|
12
|
-
import { SCREEN_HEADER_PORTAL_HOST
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
7
|
+
import { SCREEN_HEADER_PORTAL_HOST } from "../../../screen/ScreenContext.js";
|
|
8
|
+
import { useHeaderColor } from "../../hooks/use-header-color.js";
|
|
9
|
+
import { useLargeTitleHeader } from "../../hooks/use-large-title-header.js";
|
|
15
10
|
import { HeaderAccessory, HeaderAccessorySpacer } from "../../parts/HeaderAccessory.js";
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
|
|
20
|
-
const AnimatedText = Animated.createAnimatedComponent(Text);
|
|
21
|
-
|
|
22
|
-
/** Compact title offset (px) when the large title is fully expanded. */
|
|
23
|
-
const COMPACT_TITLE_SLIDE_OFFSET = 8;
|
|
24
|
-
/** Large title offset (px) when fully collapsed. */
|
|
25
|
-
const LARGE_TITLE_SLIDE_OFFSET = 6;
|
|
26
|
-
function LargeTitlePortalContent({
|
|
27
|
-
title,
|
|
28
|
-
overline,
|
|
29
|
-
subtitle,
|
|
30
|
-
hasAccessoryBelow,
|
|
31
|
-
onHeightChange
|
|
32
|
-
}) {
|
|
33
|
-
const {
|
|
34
|
-
theme
|
|
35
|
-
} = useUnistyles();
|
|
36
|
-
const {
|
|
37
|
-
scrollY
|
|
38
|
-
} = useScreen();
|
|
39
|
-
const headerCollapseHeight = theme.layout.header.height;
|
|
40
|
-
const largeTitleAnimatedStyle = useAnimatedStyle(() => {
|
|
41
|
-
const height = headerCollapseHeight;
|
|
42
|
-
if (height <= 0) {
|
|
43
|
-
return {
|
|
44
|
-
opacity: 1,
|
|
45
|
-
transform: [{
|
|
46
|
-
translateY: 0
|
|
47
|
-
}]
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
return {
|
|
51
|
-
opacity: interpolate(scrollY.value, [0, height], [1, 0], "clamp"),
|
|
52
|
-
transform: [{
|
|
53
|
-
translateY: interpolate(scrollY.value, [0, height], [0, -LARGE_TITLE_SLIDE_OFFSET], "clamp")
|
|
54
|
-
}]
|
|
55
|
-
};
|
|
56
|
-
});
|
|
57
|
-
|
|
58
|
-
// Layout height excludes the collapse transform.
|
|
59
|
-
const handleLayout = event => onHeightChange?.(event.nativeEvent.layout.height);
|
|
60
|
-
return /*#__PURE__*/_jsxs(Animated.View, {
|
|
61
|
-
style: [styles.portalContent(hasAccessoryBelow), largeTitleAnimatedStyle],
|
|
62
|
-
onLayout: handleLayout,
|
|
63
|
-
children: [!!overline && /*#__PURE__*/_jsx(Text, {
|
|
64
|
-
style: styles.overline,
|
|
65
|
-
maxFontSizeMultiplier: theme.typography.variants["label-sm"].maxFontSizeMultiplier,
|
|
66
|
-
children: overline
|
|
67
|
-
}), isTextTitle(title) ? /*#__PURE__*/_jsx(Text, {
|
|
68
|
-
style: styles.largeTitle,
|
|
69
|
-
maxFontSizeMultiplier: theme.typography.variants["headline-lg"].maxFontSizeMultiplier,
|
|
70
|
-
children: title
|
|
71
|
-
}) : title, !!subtitle && /*#__PURE__*/_jsx(Text, {
|
|
72
|
-
style: styles.subtitle,
|
|
73
|
-
maxFontSizeMultiplier: theme.typography.variants["body-lg"].maxFontSizeMultiplier,
|
|
74
|
-
children: subtitle
|
|
75
|
-
})]
|
|
76
|
-
});
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
/**
|
|
80
|
-
* iOS-style collapsing large-title header. The large title is injected (via the
|
|
81
|
-
* `Screen`'s portal) into the top of the scroll content, so it scrolls away
|
|
82
|
-
* naturally; the compact title cross-fades over the theme header height.
|
|
83
|
-
* The top safe area and bar overlay fade from transparent when expanded to
|
|
84
|
-
* the header background when collapsed. The large-title content stays transparent.
|
|
85
|
-
* Snapping is opt-in through the scroll container's snapToOffsets.
|
|
86
|
-
*
|
|
87
|
-
* Must be used inside a `Screen` with a `Screen.ScrollView` or `Screen.List`.
|
|
88
|
-
*
|
|
89
|
-
* @example
|
|
90
|
-
* ```tsx
|
|
91
|
-
* <Screen.Header>
|
|
92
|
-
* <Header.LargeTitle
|
|
93
|
-
* overline="Today"
|
|
94
|
-
* title="Meditate"
|
|
95
|
-
* subtitle="Good morning"
|
|
96
|
-
* />
|
|
97
|
-
* </Screen.Header>
|
|
98
|
-
* ```
|
|
99
|
-
*/
|
|
11
|
+
import { HeaderBar } from "../../parts/HeaderBar.js";
|
|
12
|
+
import { LargeTitleContent } from "./parts/LargeTitleContent.js";
|
|
13
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
|
+
/** Collapsing header. The expanded title lives in scroll content; the bar and accessory overlay it. */
|
|
100
15
|
export function LargeTitleHeader({
|
|
101
16
|
title,
|
|
102
17
|
overline,
|
|
@@ -108,209 +23,55 @@ export function LargeTitleHeader({
|
|
|
108
23
|
accessory,
|
|
109
24
|
accessoryPadding = "x",
|
|
110
25
|
accessoryBehavior = "sticky",
|
|
111
|
-
dismissAction = "none",
|
|
112
|
-
navigation,
|
|
113
|
-
onDismiss,
|
|
114
26
|
titleAlignment = "center",
|
|
115
27
|
isLargeTitleHidden = false,
|
|
116
28
|
background,
|
|
117
|
-
bg
|
|
29
|
+
bg,
|
|
30
|
+
...dismissProps
|
|
118
31
|
}) {
|
|
119
|
-
const
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
background: screenBackground,
|
|
125
|
-
setHeaderAccessoryHeight,
|
|
126
|
-
contentTopPadding
|
|
127
|
-
} = useScreen();
|
|
128
|
-
const colorToken = background ?? bg;
|
|
129
|
-
const bgColor = (colorToken ? resolveThemeColor(colorToken, theme) : screenBackground) ?? theme.color["surface.canvas"];
|
|
130
|
-
const leadingContent = leadingActions !== undefined ? leadingActions : LeftToolbar;
|
|
131
|
-
const trailingContent = trailingActions !== undefined ? trailingActions : RightToolbar;
|
|
132
|
-
const gradientColor = bgColor;
|
|
133
|
-
const isSticky = accessoryBehavior === "sticky" && !isLargeTitleHidden;
|
|
134
|
-
const hasStickyAccessory = isSticky && accessory != null;
|
|
135
|
-
// Sticky accessories reserve space below the large title; pinned ones add top padding.
|
|
136
|
-
const [stickyAccessoryHeight, setStickyAccessoryHeight] = useState(0);
|
|
137
|
-
const [largeTitleHeight, setLargeTitleHeight] = useState(0);
|
|
138
|
-
const isLargeTitleHiddenValue = useSharedValue(isLargeTitleHidden);
|
|
139
|
-
const handleAccessoryHeightChange = useCallback(height => {
|
|
140
|
-
if (isSticky) setStickyAccessoryHeight(Math.max(0, Math.round(height)));else setHeaderAccessoryHeight(height);
|
|
141
|
-
}, [isSticky, setHeaderAccessoryHeight]);
|
|
142
|
-
const handleLargeTitleHeightChange = useCallback(height => {
|
|
143
|
-
setLargeTitleHeight(Math.max(0, Math.round(height)));
|
|
144
|
-
}, []);
|
|
145
|
-
|
|
146
|
-
// Rest below the title, including the scroll container's top padding.
|
|
147
|
-
const stickyAccessoryOffset = Math.max(0, contentTopPadding + largeTitleHeight - theme.layout.header.height);
|
|
148
|
-
|
|
149
|
-
// Zero translation places the accessory directly below the compact bar.
|
|
150
|
-
const stickyAccessoryStyle = useAnimatedStyle(() => {
|
|
151
|
-
if (isLargeTitleHiddenValue.value) {
|
|
152
|
-
return {
|
|
153
|
-
transform: [{
|
|
154
|
-
translateY: 0
|
|
155
|
-
}]
|
|
156
|
-
};
|
|
157
|
-
}
|
|
158
|
-
return {
|
|
159
|
-
transform: [{
|
|
160
|
-
translateY: Math.max(0, stickyAccessoryOffset - scrollY.value)
|
|
161
|
-
}]
|
|
162
|
-
};
|
|
32
|
+
const color = useHeaderColor(background ?? bg);
|
|
33
|
+
const layout = useLargeTitleHeader({
|
|
34
|
+
hasAccessory: accessory != null,
|
|
35
|
+
accessoryBehavior,
|
|
36
|
+
isLargeTitleHidden
|
|
163
37
|
});
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
// Animate the gradient overlay's opacity: 0 (expanded) → 1 (collapsed).
|
|
181
|
-
const gradientOpacityStyle = useAnimatedStyle(() => {
|
|
182
|
-
if (isLargeTitleHiddenValue.value) {
|
|
183
|
-
return {
|
|
184
|
-
opacity: 1
|
|
185
|
-
};
|
|
186
|
-
}
|
|
187
|
-
const height = hasStickyAccessory ? stickyAccessoryOffset : headerCollapseHeight;
|
|
188
|
-
if (height <= 0) {
|
|
189
|
-
return {
|
|
190
|
-
opacity: hasStickyAccessory ? 1 : 0
|
|
191
|
-
};
|
|
192
|
-
}
|
|
193
|
-
return {
|
|
194
|
-
opacity: interpolate(scrollY.value, [0, height], [0, 1], "clamp")
|
|
195
|
-
};
|
|
196
|
-
});
|
|
197
|
-
useHeaderBackground(bgColor, gradientOpacityStyle);
|
|
198
|
-
const compactTitleAnimatedStyle = useAnimatedStyle(() => {
|
|
199
|
-
if (isLargeTitleHiddenValue.value) {
|
|
200
|
-
return {
|
|
201
|
-
opacity: 1,
|
|
202
|
-
transform: [{
|
|
203
|
-
translateY: 0
|
|
204
|
-
}]
|
|
205
|
-
};
|
|
206
|
-
}
|
|
207
|
-
const height = headerCollapseHeight;
|
|
208
|
-
if (height <= 0) {
|
|
209
|
-
return {
|
|
210
|
-
opacity: 0,
|
|
211
|
-
transform: [{
|
|
212
|
-
translateY: COMPACT_TITLE_SLIDE_OFFSET
|
|
213
|
-
}]
|
|
214
|
-
};
|
|
215
|
-
}
|
|
216
|
-
return {
|
|
217
|
-
opacity: interpolate(scrollY.value, [0, height], [0, 1], "clamp"),
|
|
218
|
-
transform: [{
|
|
219
|
-
translateY: interpolate(scrollY.value, [0, height], [COMPACT_TITLE_SLIDE_OFFSET, 0], "clamp")
|
|
220
|
-
}]
|
|
221
|
-
};
|
|
222
|
-
});
|
|
223
|
-
useEffect(() => {
|
|
224
|
-
isLargeTitleHiddenValue.value = isLargeTitleHidden;
|
|
225
|
-
}, [isLargeTitleHidden, isLargeTitleHiddenValue]);
|
|
226
|
-
const leading = dismissAction === "back" ? /*#__PURE__*/_jsxs(_Fragment, {
|
|
227
|
-
children: [/*#__PURE__*/_jsx(HeaderDismissButton, {
|
|
228
|
-
dismissAction: dismissAction,
|
|
229
|
-
navigation: navigation,
|
|
230
|
-
onDismiss: onDismiss
|
|
231
|
-
}), leadingContent]
|
|
232
|
-
}) : leadingContent;
|
|
233
|
-
const trailing = dismissAction === "close" ? /*#__PURE__*/_jsxs(_Fragment, {
|
|
234
|
-
children: [trailingContent, /*#__PURE__*/_jsx(HeaderDismissButton, {
|
|
235
|
-
dismissAction: dismissAction,
|
|
236
|
-
navigation: navigation,
|
|
237
|
-
onDismiss: onDismiss
|
|
38
|
+
useHeaderBackground(color, layout.surfaceStyle);
|
|
39
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
40
|
+
style: styles.container(layout.accessoryOffset),
|
|
41
|
+
pointerEvents: "box-none",
|
|
42
|
+
children: [!isLargeTitleHidden && /*#__PURE__*/_jsxs(Portal, {
|
|
43
|
+
hostName: SCREEN_HEADER_PORTAL_HOST,
|
|
44
|
+
children: [/*#__PURE__*/_jsx(LargeTitleContent, {
|
|
45
|
+
title: title,
|
|
46
|
+
overline: overline,
|
|
47
|
+
subtitle: subtitle,
|
|
48
|
+
hasAccessoryBelow: layout.isSticky,
|
|
49
|
+
onHeightChange: layout.setLargeTitleHeight,
|
|
50
|
+
animatedStyle: layout.largeTitleStyle
|
|
51
|
+
}), layout.isSticky && /*#__PURE__*/_jsx(HeaderAccessorySpacer, {
|
|
52
|
+
height: layout.reservedAccessoryHeight
|
|
238
53
|
})]
|
|
239
|
-
})
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
}), hasStickyAccessory && /*#__PURE__*/_jsx(Animated.View, {
|
|
258
|
-
style: [styles.stickySurface, stickySurfaceStyle],
|
|
259
|
-
pointerEvents: "none",
|
|
260
|
-
children: /*#__PURE__*/_jsx(HeaderSurface, {
|
|
261
|
-
color: gradientColor,
|
|
262
|
-
animatedStyle: gradientOpacityStyle
|
|
263
|
-
})
|
|
264
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
265
|
-
style: styles.barGroup,
|
|
266
|
-
children: [!hasStickyAccessory && /*#__PURE__*/_jsx(HeaderSurface, {
|
|
267
|
-
color: gradientColor,
|
|
268
|
-
animatedStyle: gradientOpacityStyle
|
|
269
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
270
|
-
style: styles.bar,
|
|
271
|
-
children: [leading != null && /*#__PURE__*/_jsx(Toolbar, {
|
|
272
|
-
children: leading
|
|
273
|
-
}), /*#__PURE__*/_jsx(Animated.View, {
|
|
274
|
-
style: [styles.titleContainer, compactTitleAnimatedStyle],
|
|
275
|
-
pointerEvents: isCustomTitle(title) ? "box-none" : "none",
|
|
276
|
-
children: isTextTitle(title) ? /*#__PURE__*/_jsx(AnimatedText, {
|
|
277
|
-
style: styles.compactTitle,
|
|
278
|
-
maxFontSizeMultiplier: theme.typography.variants["title-md"].maxFontSizeMultiplier,
|
|
279
|
-
children: title
|
|
280
|
-
}) : title
|
|
281
|
-
}), trailing != null && /*#__PURE__*/_jsx(Toolbar, {
|
|
282
|
-
style: styles.trailing,
|
|
283
|
-
children: trailing
|
|
284
|
-
})]
|
|
285
|
-
}), accessory != null && !isSticky && /*#__PURE__*/_jsx(HeaderAccessory, {
|
|
286
|
-
padding: accessoryPadding,
|
|
287
|
-
onHeightChange: handleAccessoryHeightChange,
|
|
288
|
-
children: accessory
|
|
289
|
-
})]
|
|
290
|
-
}), accessory != null && isSticky && /*#__PURE__*/_jsxs(Animated.View, {
|
|
291
|
-
style: [styles.stickyAccessory, stickyAccessoryStyle],
|
|
292
|
-
children: [/*#__PURE__*/_jsx(HeaderSurface, {
|
|
293
|
-
color: screenBackground ?? theme.color["surface.canvas"],
|
|
294
|
-
animatedStyle: accessorySurfaceStyle,
|
|
295
|
-
fadeHeight: HEADER_FADE_EXTENT
|
|
296
|
-
}), /*#__PURE__*/_jsx(HeaderAccessory, {
|
|
297
|
-
padding: accessoryPadding,
|
|
298
|
-
onHeightChange: handleAccessoryHeightChange,
|
|
299
|
-
children: accessory
|
|
300
|
-
})]
|
|
301
|
-
})]
|
|
302
|
-
})
|
|
303
|
-
);
|
|
304
|
-
}
|
|
54
|
+
}), /*#__PURE__*/_jsx(HeaderBar, {
|
|
55
|
+
...dismissProps,
|
|
56
|
+
title: title,
|
|
57
|
+
titleAlignment: titleAlignment,
|
|
58
|
+
color: color,
|
|
59
|
+
surfaceStyle: layout.surfaceStyle,
|
|
60
|
+
titleStyle: layout.compactTitleStyle,
|
|
61
|
+
leading: leadingActions !== undefined ? leadingActions : LeftToolbar,
|
|
62
|
+
trailing: trailingActions !== undefined ? trailingActions : RightToolbar
|
|
63
|
+
}), accessory != null && /*#__PURE__*/_jsx(HeaderAccessory, {
|
|
64
|
+
padding: accessoryPadding,
|
|
65
|
+
color: color,
|
|
66
|
+
surfaceStyle: layout.surfaceStyle,
|
|
67
|
+
style: layout.accessoryStyle,
|
|
68
|
+
onHeightChange: layout.setAccessoryHeight,
|
|
69
|
+
children: accessory
|
|
70
|
+
})]
|
|
71
|
+
});
|
|
305
72
|
}
|
|
306
|
-
const styles = StyleSheet.create(
|
|
307
|
-
|
|
308
|
-
position: "absolute",
|
|
309
|
-
top: 0,
|
|
310
|
-
left: 0,
|
|
311
|
-
right: 0
|
|
312
|
-
},
|
|
313
|
-
// Include the translated accessory in the parent's touchable bounds.
|
|
73
|
+
const styles = StyleSheet.create(() => ({
|
|
74
|
+
// Keep the translated accessory inside the overlay's touchable bounds.
|
|
314
75
|
container: accessoryOffset => ({
|
|
315
76
|
position: "absolute",
|
|
316
77
|
top: 0,
|
|
@@ -318,104 +79,6 @@ const styles = StyleSheet.create(theme => ({
|
|
|
318
79
|
right: 0,
|
|
319
80
|
zIndex: 1000,
|
|
320
81
|
paddingBottom: accessoryOffset
|
|
321
|
-
})
|
|
322
|
-
// Normal flow places the accessory directly below the bar.
|
|
323
|
-
stickyAccessory: {
|
|
324
|
-
position: "relative"
|
|
325
|
-
},
|
|
326
|
-
// Anchors the absolutely positioned surface over the bar and the accessory both.
|
|
327
|
-
barGroup: {
|
|
328
|
-
position: "relative"
|
|
329
|
-
},
|
|
330
|
-
bar: {
|
|
331
|
-
height: theme.layout.header.height,
|
|
332
|
-
flexDirection: "row",
|
|
333
|
-
alignItems: "center",
|
|
334
|
-
paddingHorizontal: theme.layout.screen.padding.x,
|
|
335
|
-
gap: theme.spacing["3"],
|
|
336
|
-
justifyContent: "space-between",
|
|
337
|
-
uni__dependencies: [0]
|
|
338
|
-
},
|
|
339
|
-
// A centered title is absolutely positioned, so it leaves the flex row. With
|
|
340
|
-
// no leading slot the trailing toolbar would be the only in-flow child and
|
|
341
|
-
// `space-between` would park it on the left — the auto margin pins it right.
|
|
342
|
-
trailing: {
|
|
343
|
-
justifyContent: "flex-end",
|
|
344
|
-
variants: {
|
|
345
|
-
titleAlignment: {
|
|
346
|
-
center: {
|
|
347
|
-
marginLeft: "auto"
|
|
348
|
-
},
|
|
349
|
-
left: {}
|
|
350
|
-
}
|
|
351
|
-
},
|
|
352
|
-
uni__dependencies: [4]
|
|
353
|
-
},
|
|
354
|
-
portalContent: hasAccessoryBelow => ({
|
|
355
|
-
gap: 2,
|
|
356
|
-
// Include the gap in the measured height used to position the accessory.
|
|
357
|
-
paddingBottom: hasAccessoryBelow ? theme.spacing["2"] : 0,
|
|
358
|
-
paddingHorizontal: theme.layout.screen.padding.x,
|
|
359
|
-
uni__dependencies: [0]
|
|
360
|
-
}),
|
|
361
|
-
overline: {
|
|
362
|
-
fontSize: theme.typography.variants["label-sm"].fontSize,
|
|
363
|
-
lineHeight: theme.typography.variants["label-sm"].lineHeight,
|
|
364
|
-
letterSpacing: theme.typography.variants["label-sm"].letterSpacing,
|
|
365
|
-
fontWeight: FONT_WEIGHT_VALUE[theme.typography.variants["label-sm"].fontWeight],
|
|
366
|
-
color: theme.color["text.tertiary"] ?? "",
|
|
367
|
-
uni__dependencies: [0]
|
|
368
|
-
},
|
|
369
|
-
largeTitle: {
|
|
370
|
-
fontSize: theme.typography.variants["headline-lg"].fontSize,
|
|
371
|
-
lineHeight: theme.typography.variants["headline-lg"].lineHeight,
|
|
372
|
-
letterSpacing: theme.typography.variants["headline-lg"].letterSpacing,
|
|
373
|
-
fontWeight: FONT_WEIGHT_VALUE[theme.typography.variants["headline-lg"].fontWeight],
|
|
374
|
-
color: theme.color["text.primary"] ?? "",
|
|
375
|
-
uni__dependencies: [0]
|
|
376
|
-
},
|
|
377
|
-
subtitle: {
|
|
378
|
-
fontSize: theme.typography.variants["body-lg"].fontSize,
|
|
379
|
-
lineHeight: theme.typography.variants["body-lg"].lineHeight,
|
|
380
|
-
letterSpacing: theme.typography.variants["body-lg"].letterSpacing,
|
|
381
|
-
color: theme.color["text.tertiary"] ?? "",
|
|
382
|
-
uni__dependencies: [0]
|
|
383
|
-
},
|
|
384
|
-
compactTitle: {
|
|
385
|
-
fontSize: theme.typography.variants["title-md"].fontSize,
|
|
386
|
-
lineHeight: theme.typography.variants["title-md"].lineHeight,
|
|
387
|
-
letterSpacing: theme.typography.variants["title-md"].letterSpacing,
|
|
388
|
-
fontWeight: FONT_WEIGHT_VALUE[theme.typography.variants["title-md"].fontWeight],
|
|
389
|
-
color: theme.color["text.primary"] ?? "",
|
|
390
|
-
variants: {
|
|
391
|
-
titleAlignment: {
|
|
392
|
-
center: {
|
|
393
|
-
textAlign: "center"
|
|
394
|
-
},
|
|
395
|
-
left: {
|
|
396
|
-
textAlign: "left"
|
|
397
|
-
}
|
|
398
|
-
}
|
|
399
|
-
},
|
|
400
|
-
uni__dependencies: [0, 4]
|
|
401
|
-
},
|
|
402
|
-
titleContainer: {
|
|
403
|
-
flex: 1,
|
|
404
|
-
variants: {
|
|
405
|
-
titleAlignment: {
|
|
406
|
-
center: {
|
|
407
|
-
position: "absolute",
|
|
408
|
-
left: 0,
|
|
409
|
-
right: 0,
|
|
410
|
-
alignItems: "center"
|
|
411
|
-
},
|
|
412
|
-
left: {
|
|
413
|
-
flex: 1,
|
|
414
|
-
alignItems: "flex-start"
|
|
415
|
-
}
|
|
416
|
-
}
|
|
417
|
-
},
|
|
418
|
-
uni__dependencies: [4]
|
|
419
|
-
}
|
|
82
|
+
})
|
|
420
83
|
}));
|
|
421
84
|
//# sourceMappingURL=index.js.map
|
|
@@ -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","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","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","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,wBAAwB,GAAG,CAAC;AAsBlC,SAASC,uBAAuBA,CAAC;EAC/BC,KAAK;EACLC,QAAQ;EACRC,QAAQ;EACRC,iBAAiB;EACjBC;AAMF,CAAC,EAAE;EACD,MAAM;IAAEC;EAAM,CAAC,GAAGhC,YAAY,CAAC,CAAC;EAChC,MAAM;IAAEiC;EAAQ,CAAC,GAAG3B,SAAS,CAAC,CAAC;EAE/B,MAAM4B,oBAAoB,GAAGF,KAAK,CAACG,MAAM,CAACC,MAAM,C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E;MACRa,cAAc,EAAE;QACdiE,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;IACPrF,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;UACJqB,IAAI,EAAE,CAAC;UACPf,UAAU,EAAE;QACd;MACF;IACF,CAAC;IAAAO,iBAAA;EACH;AACF,CAAC,CAAC,CAAC","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["StyleSheet","Portal","useHeaderBackground","SCREEN_HEADER_PORTAL_HOST","useHeaderColor","useLargeTitleHeader","HeaderAccessory","HeaderAccessorySpacer","HeaderBar","LargeTitleContent","jsx","_jsx","jsxs","_jsxs","LargeTitleHeader","title","overline","subtitle","leadingActions","trailingActions","LeftToolbar","RightToolbar","accessory","accessoryPadding","accessoryBehavior","titleAlignment","isLargeTitleHidden","background","bg","dismissProps","color","layout","hasAccessory","surfaceStyle","View","style","styles","container","accessoryOffset","pointerEvents","children","hostName","hasAccessoryBelow","isSticky","onHeightChange","setLargeTitleHeight","animatedStyle","largeTitleStyle","height","reservedAccessoryHeight","titleStyle","compactTitleStyle","leading","undefined","trailing","padding","accessoryStyle","setAccessoryHeight","create","position","top","left","right","zIndex","paddingBottom"],"sourceRoot":"../../../../../../src","sources":["components/header/variants/LargeTitleHeader/index.tsx"],"mappings":";;;AAEA,SAASA,UAAU,QAAQ,wBAAwB;AAEnD,SAASC,MAAM;AACf,SAASC,mBAAmB;AAC5B,SAASC,yBAAyB;AAClC,SAASC,cAAc;AACvB,SAASC,mBAAmB;AAC5B,SAASC,eAAe,EAAEC,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