@expo/ui 57.0.19 → 57.0.21
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 +23 -0
- package/android/build.gradle +2 -2
- package/android/src/main/java/expo/modules/ui/HostView.kt +6 -4
- package/android/src/main/java/expo/modules/ui/ModifierRegistry.kt +11 -3
- package/android/src/main/java/expo/modules/ui/SemanticsModifier.kt +2 -1
- package/build/jetpack-compose/colors.d.ts.map +1 -1
- package/build/jetpack-compose/modifiers/index.d.ts +15 -3
- package/build/jetpack-compose/modifiers/index.d.ts.map +1 -1
- package/build/swift-ui/Toolbar/index.d.ts +50 -0
- package/build/swift-ui/Toolbar/index.d.ts.map +1 -1
- package/build/swift-ui/modifiers/index.d.ts +15 -1
- package/build/swift-ui/modifiers/index.d.ts.map +1 -1
- package/build/swift-ui/modifiers/presentationModifiers.d.ts +8 -0
- package/build/swift-ui/modifiers/presentationModifiers.d.ts.map +1 -1
- package/build/universal/State.android.d.ts +1 -3
- package/build/universal/State.android.d.ts.map +1 -1
- package/build/universal/State.d.ts +2 -3
- package/build/universal/State.d.ts.map +1 -1
- package/build/universal/State.ios.d.ts +1 -3
- package/build/universal/State.ios.d.ts.map +1 -1
- package/build/universal/transformStyle.ios.d.ts.map +1 -1
- package/build/universal/types.d.ts +24 -0
- package/build/universal/types.d.ts.map +1 -1
- package/expo-module.config.json +1 -1
- package/ios/Convertibles/ToolbarItemPlacementOptions.swift +110 -0
- package/ios/Convertibles/ToolbarItemVisibilityPriorityOptions.swift +35 -0
- package/ios/Modifiers/PresentationModifiers.swift +10 -0
- package/ios/Modifiers/ScrollEdgeEffectStyleModifier.swift +34 -0
- package/ios/Modifiers/ViewModifierRegistry.swift +8 -0
- package/ios/ToolbarView.swift +88 -4
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/{57.0.19/expo.modules.ui-57.0.19-sources.jar → 57.0.21/expo.modules.ui-57.0.21-sources.jar} +0 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21-sources.jar.md5 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21-sources.jar.sha1 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21-sources.jar.sha256 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21-sources.jar.sha512 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar +0 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar.md5 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar.sha1 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar.sha256 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar.sha512 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/{57.0.19/expo.modules.ui-57.0.19.module → 57.0.21/expo.modules.ui-57.0.21.module} +22 -22
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.module.md5 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.module.sha1 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.module.sha256 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.module.sha512 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/{57.0.19/expo.modules.ui-57.0.19.pom → 57.0.21/expo.modules.ui-57.0.21.pom} +1 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.pom.md5 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.pom.sha1 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.pom.sha256 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.pom.sha512 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml +4 -4
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml.md5 +1 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml.sha1 +1 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml.sha256 +1 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml.sha512 +1 -1
- package/package.json +4 -4
- package/src/jetpack-compose/colors.ts +23 -1
- package/src/jetpack-compose/modifiers/index.ts +16 -1
- package/src/swift-ui/Toolbar/index.tsx +79 -0
- package/src/swift-ui/modifiers/index.ts +19 -0
- package/src/swift-ui/modifiers/presentationModifiers.ts +10 -0
- package/src/universal/State.android.ts +1 -1
- package/src/universal/State.ios.ts +1 -1
- package/src/universal/State.ts +12 -4
- package/src/universal/transformStyle.ios.ts +5 -2
- package/src/universal/types.ts +27 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19-sources.jar.md5 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19-sources.jar.sha1 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19-sources.jar.sha256 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19-sources.jar.sha512 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.aar +0 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.aar.md5 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.aar.sha1 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.aar.sha256 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.aar.sha512 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.module.md5 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.module.sha1 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.module.sha256 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.module.sha512 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.pom.md5 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.pom.sha1 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.pom.sha256 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.19/expo.modules.ui-57.0.19.pom.sha512 +0 -1
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
// Copyright 2025-present 650 Industries. All rights reserved.
|
|
2
|
+
|
|
3
|
+
import ExpoModulesCore
|
|
4
|
+
import SwiftUI
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
Where an item sits in the toolbar, matching SwiftUI's `ToolbarItemPlacement`.
|
|
8
|
+
*/
|
|
9
|
+
internal enum ToolbarItemPlacementOptions: String, Enumerable {
|
|
10
|
+
case automatic
|
|
11
|
+
case principal
|
|
12
|
+
case navigation
|
|
13
|
+
case primaryAction
|
|
14
|
+
case secondaryAction
|
|
15
|
+
case status
|
|
16
|
+
case confirmationAction
|
|
17
|
+
case cancellationAction
|
|
18
|
+
case destructiveAction
|
|
19
|
+
case keyboard
|
|
20
|
+
case topBarLeading
|
|
21
|
+
case topBarTrailing
|
|
22
|
+
case topBarPinnedTrailing
|
|
23
|
+
case largeTitle
|
|
24
|
+
case bottomBar
|
|
25
|
+
|
|
26
|
+
func toPlacement() -> ToolbarItemPlacement {
|
|
27
|
+
switch self {
|
|
28
|
+
case .automatic:
|
|
29
|
+
return .automatic
|
|
30
|
+
case .principal:
|
|
31
|
+
return .principal
|
|
32
|
+
case .navigation:
|
|
33
|
+
return .navigation
|
|
34
|
+
case .primaryAction:
|
|
35
|
+
return .primaryAction
|
|
36
|
+
case .confirmationAction:
|
|
37
|
+
return .confirmationAction
|
|
38
|
+
case .cancellationAction:
|
|
39
|
+
return .cancellationAction
|
|
40
|
+
case .destructiveAction:
|
|
41
|
+
return .destructiveAction
|
|
42
|
+
|
|
43
|
+
case .secondaryAction:
|
|
44
|
+
#if os(tvOS)
|
|
45
|
+
return .automatic
|
|
46
|
+
#else
|
|
47
|
+
return .secondaryAction
|
|
48
|
+
#endif
|
|
49
|
+
|
|
50
|
+
case .status:
|
|
51
|
+
#if os(tvOS)
|
|
52
|
+
if #available(tvOS 18.0, *) {
|
|
53
|
+
return .status
|
|
54
|
+
}
|
|
55
|
+
return .automatic
|
|
56
|
+
#else
|
|
57
|
+
return .status
|
|
58
|
+
#endif
|
|
59
|
+
|
|
60
|
+
case .keyboard:
|
|
61
|
+
#if os(iOS)
|
|
62
|
+
return .keyboard
|
|
63
|
+
#else
|
|
64
|
+
return .automatic
|
|
65
|
+
#endif
|
|
66
|
+
|
|
67
|
+
case .topBarLeading:
|
|
68
|
+
#if os(macOS)
|
|
69
|
+
return .automatic
|
|
70
|
+
#else
|
|
71
|
+
return .topBarLeading
|
|
72
|
+
#endif
|
|
73
|
+
|
|
74
|
+
case .topBarTrailing:
|
|
75
|
+
#if os(macOS)
|
|
76
|
+
return .automatic
|
|
77
|
+
#else
|
|
78
|
+
return .topBarTrailing
|
|
79
|
+
#endif
|
|
80
|
+
|
|
81
|
+
case .topBarPinnedTrailing:
|
|
82
|
+
#if os(iOS) && compiler(>=6.4) // Xcode 27
|
|
83
|
+
if #available(iOS 27.0, *) {
|
|
84
|
+
return .topBarPinnedTrailing
|
|
85
|
+
}
|
|
86
|
+
#endif
|
|
87
|
+
return .automatic
|
|
88
|
+
|
|
89
|
+
case .largeTitle:
|
|
90
|
+
#if os(iOS) && compiler(>=6.2) // Xcode 26
|
|
91
|
+
if #available(iOS 26.0, *) {
|
|
92
|
+
return .largeTitle
|
|
93
|
+
}
|
|
94
|
+
#endif
|
|
95
|
+
return .automatic
|
|
96
|
+
|
|
97
|
+
case .bottomBar:
|
|
98
|
+
#if os(tvOS)
|
|
99
|
+
if #available(tvOS 18.0, *) {
|
|
100
|
+
return .bottomBar
|
|
101
|
+
}
|
|
102
|
+
return .automatic
|
|
103
|
+
#elseif os(macOS)
|
|
104
|
+
return .automatic
|
|
105
|
+
#else
|
|
106
|
+
return .bottomBar
|
|
107
|
+
#endif
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
// Copyright 2025-present 650 Industries. All rights reserved.
|
|
2
|
+
|
|
3
|
+
import ExpoModulesCore
|
|
4
|
+
import SwiftUI
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
How readily a toolbar item gives up its place, matching SwiftUI's `ToolbarItemVisibilityPriority`.
|
|
8
|
+
*/
|
|
9
|
+
internal enum ToolbarItemVisibilityPriorityOptions: String, Enumerable {
|
|
10
|
+
case automatic
|
|
11
|
+
case low
|
|
12
|
+
case high
|
|
13
|
+
|
|
14
|
+
#if compiler(>=6.4) // Xcode 27
|
|
15
|
+
@available(iOS 27.0, macOS 26.1, tvOS 27.0, visionOS 27.0, *)
|
|
16
|
+
func toPriority() -> ToolbarItemVisibilityPriority {
|
|
17
|
+
switch self {
|
|
18
|
+
case .automatic:
|
|
19
|
+
return .automatic
|
|
20
|
+
case .low:
|
|
21
|
+
#if os(iOS) || os(macOS)
|
|
22
|
+
return .low
|
|
23
|
+
#else
|
|
24
|
+
return .automatic
|
|
25
|
+
#endif
|
|
26
|
+
case .high:
|
|
27
|
+
#if os(iOS) || os(macOS)
|
|
28
|
+
return .high
|
|
29
|
+
#else
|
|
30
|
+
return .automatic
|
|
31
|
+
#endif
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
#endif
|
|
35
|
+
}
|
|
@@ -160,6 +160,16 @@ internal struct PresentationDragIndicatorModifier: ViewModifier, Record {
|
|
|
160
160
|
}
|
|
161
161
|
}
|
|
162
162
|
|
|
163
|
+
// MARK: - Presentation Corner Radius
|
|
164
|
+
|
|
165
|
+
internal struct PresentationCornerRadiusModifier: ViewModifier, Record {
|
|
166
|
+
@Field var cornerRadius: Double?
|
|
167
|
+
|
|
168
|
+
func body(content: Content) -> some View {
|
|
169
|
+
content.presentationCornerRadius(cornerRadius.map { CGFloat($0) })
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
|
|
163
173
|
// MARK: - Presentation Background Interaction
|
|
164
174
|
|
|
165
175
|
internal enum PresentationBackgroundInteractionTypeModifier: String, Enumerable {
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
// Copyright 2015-present 650 Industries. All rights reserved.
|
|
2
|
+
|
|
3
|
+
import ExpoModulesCore
|
|
4
|
+
import SwiftUI
|
|
5
|
+
|
|
6
|
+
internal enum ScrollEdgeEffectStyleOptions: String, Enumerable {
|
|
7
|
+
case automatic
|
|
8
|
+
case hard
|
|
9
|
+
case soft
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
internal struct ScrollEdgeEffectStyleModifier: ViewModifier, Record {
|
|
13
|
+
@Field var style: ScrollEdgeEffectStyleOptions = .automatic
|
|
14
|
+
@Field var edges: EdgeOptions = .all
|
|
15
|
+
|
|
16
|
+
func body(content: Content) -> some View {
|
|
17
|
+
#if compiler(>=6.2) && !os(tvOS) && !os(macOS) // Xcode 26
|
|
18
|
+
if #available(iOS 26.0, *) {
|
|
19
|
+
switch style {
|
|
20
|
+
case .automatic:
|
|
21
|
+
content.scrollEdgeEffectStyle(.automatic, for: edges.toEdge())
|
|
22
|
+
case .hard:
|
|
23
|
+
content.scrollEdgeEffectStyle(.hard, for: edges.toEdge())
|
|
24
|
+
case .soft:
|
|
25
|
+
content.scrollEdgeEffectStyle(.soft, for: edges.toEdge())
|
|
26
|
+
}
|
|
27
|
+
} else {
|
|
28
|
+
content
|
|
29
|
+
}
|
|
30
|
+
#else
|
|
31
|
+
content
|
|
32
|
+
#endif
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -2313,6 +2313,10 @@ extension ViewModifierRegistry {
|
|
|
2313
2313
|
return try ScrollIndicatorsModifier(from: params, appContext: appContext)
|
|
2314
2314
|
}
|
|
2315
2315
|
|
|
2316
|
+
register("scrollEdgeEffectStyle") { params, appContext, _ in
|
|
2317
|
+
return try ScrollEdgeEffectStyleModifier(from: params, appContext: appContext)
|
|
2318
|
+
}
|
|
2319
|
+
|
|
2316
2320
|
register("tabViewStyle") { params, appContext, _ in
|
|
2317
2321
|
return try TabViewStyleModifier(from: params, appContext: appContext)
|
|
2318
2322
|
}
|
|
@@ -2345,6 +2349,10 @@ extension ViewModifierRegistry {
|
|
|
2345
2349
|
return try PresentationDragIndicatorModifier(from: params, appContext: appContext)
|
|
2346
2350
|
}
|
|
2347
2351
|
|
|
2352
|
+
register("presentationCornerRadius") { params, appContext, _ in
|
|
2353
|
+
return try PresentationCornerRadiusModifier(from: params, appContext: appContext)
|
|
2354
|
+
}
|
|
2355
|
+
|
|
2348
2356
|
register("presentationBackgroundInteraction") { params, appContext, _ in
|
|
2349
2357
|
return try PresentationBackgroundInteractionModifier(from: params, appContext: appContext)
|
|
2350
2358
|
}
|
package/ios/ToolbarView.swift
CHANGED
|
@@ -5,6 +5,42 @@ import ExpoModulesCore
|
|
|
5
5
|
|
|
6
6
|
internal final class ToolbarViewProps: UIBaseViewProps {}
|
|
7
7
|
|
|
8
|
+
private struct ToolbarContentView: View {
|
|
9
|
+
@ObservedObject var props: SlotViewProps
|
|
10
|
+
let content: SlotView
|
|
11
|
+
let base: AnyView
|
|
12
|
+
|
|
13
|
+
@ViewBuilder
|
|
14
|
+
var body: some View {
|
|
15
|
+
let children = props.children ?? []
|
|
16
|
+
|
|
17
|
+
if children.contains(where: isItem) {
|
|
18
|
+
children.reduce(base) { view, child in
|
|
19
|
+
let childView: any View = child.childView
|
|
20
|
+
|
|
21
|
+
guard let slot = child.childView as? SlotView, slot.props.name == "item" else {
|
|
22
|
+
return AnyView(placed(AnyView(childView), on: view, placement: .automatic, visibilityPriority: nil))
|
|
23
|
+
}
|
|
24
|
+
return AnyView(ToolbarItemLayer(props: slot.props, base: view, content: AnyView(childView)))
|
|
25
|
+
}
|
|
26
|
+
} else {
|
|
27
|
+
base.toolbar {
|
|
28
|
+
content
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
private struct ToolbarItemLayer: View {
|
|
35
|
+
@ObservedObject var props: SlotViewProps
|
|
36
|
+
let base: AnyView
|
|
37
|
+
let content: AnyView
|
|
38
|
+
|
|
39
|
+
var body: some View {
|
|
40
|
+
placed(content, on: base, placement: placement(from: props), visibilityPriority: visibilityPriority(from: props))
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
8
44
|
internal struct ToolbarView: ExpoSwiftUI.View {
|
|
9
45
|
@ObservedObject var props: ToolbarViewProps
|
|
10
46
|
|
|
@@ -14,10 +50,7 @@ internal struct ToolbarView: ExpoSwiftUI.View {
|
|
|
14
50
|
|
|
15
51
|
var body: some View {
|
|
16
52
|
if let content = props.children?.slot("content") {
|
|
17
|
-
baseContent
|
|
18
|
-
.toolbar {
|
|
19
|
-
content
|
|
20
|
-
}
|
|
53
|
+
ToolbarContentView(props: content.props, content: content, base: AnyView(baseContent))
|
|
21
54
|
} else {
|
|
22
55
|
baseContent
|
|
23
56
|
}
|
|
@@ -31,3 +64,54 @@ internal struct ToolbarView: ExpoSwiftUI.View {
|
|
|
31
64
|
}
|
|
32
65
|
}
|
|
33
66
|
}
|
|
67
|
+
|
|
68
|
+
@ViewBuilder
|
|
69
|
+
private func placed(
|
|
70
|
+
_ content: AnyView,
|
|
71
|
+
on base: AnyView,
|
|
72
|
+
placement: ToolbarItemPlacement,
|
|
73
|
+
visibilityPriority: ToolbarItemVisibilityPriorityOptions?
|
|
74
|
+
) -> some View {
|
|
75
|
+
#if compiler(>=6.4) // Xcode 27
|
|
76
|
+
if #available(iOS 27.0, macOS 26.1, tvOS 27.0, visionOS 27.0, *),
|
|
77
|
+
let visibilityPriority {
|
|
78
|
+
base.toolbar {
|
|
79
|
+
ToolbarItem(placement: placement) {
|
|
80
|
+
content
|
|
81
|
+
}
|
|
82
|
+
.visibilityPriority(visibilityPriority.toPriority())
|
|
83
|
+
}
|
|
84
|
+
} else {
|
|
85
|
+
base.toolbar {
|
|
86
|
+
ToolbarItem(placement: placement) {
|
|
87
|
+
content
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
#else
|
|
92
|
+
base.toolbar {
|
|
93
|
+
ToolbarItem(placement: placement) {
|
|
94
|
+
content
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
#endif
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
private func isItem(_ child: any ExpoSwiftUI.AnyChild) -> Bool {
|
|
101
|
+
return (child.childView as? SlotView)?.props.name == "item"
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
private func placement(from props: SlotViewProps) -> ToolbarItemPlacement {
|
|
105
|
+
guard let rawPlacement = props.extraProps?["placement"] as? String,
|
|
106
|
+
let placement = ToolbarItemPlacementOptions(rawValue: rawPlacement) else {
|
|
107
|
+
return .automatic
|
|
108
|
+
}
|
|
109
|
+
return placement.toPlacement()
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
private func visibilityPriority(from props: SlotViewProps) -> ToolbarItemVisibilityPriorityOptions? {
|
|
113
|
+
guard let rawPriority = props.extraProps?["visibilityPriority"] as? String else {
|
|
114
|
+
return nil
|
|
115
|
+
}
|
|
116
|
+
return ToolbarItemVisibilityPriorityOptions(rawValue: rawPriority)
|
|
117
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
711eb23ebb503bc13f871f580afcbcf0
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
ca977e2408458c690c3555514485a6a8e7fade24
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
352b556c7e482ce79471552b5d73a5f29d92e9a339fd3edecf327c7df9e6576b
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
bd014a7ec6f4940b753de1ef54b686c8316d45a4242893e9a508948dd22fc893063a285538d30a3fa943deedbf32915697892ff4a739e17fcb2b194a79f71d8d
|
|
Binary file
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar.md5
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
8b8ece627534269af4e6dfa665f46f6c
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar.sha1
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
b8495e88a2dd3b3386885867acede44c5a99186f
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar.sha256
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
edfc30f6ff0935cee758638ea4443ec247e3628ba4a088f44f58becfca185b6e
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.aar.sha512
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
894745399f2255f02b84f664c1e62ab66d71daf4a24e3ce48ecfb7e60d0ba9abfbe31a5d9517953e2d365b786ba9da8ba8f476361777fd57006eb7fb7522c32c
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"component": {
|
|
4
4
|
"group": "expo.modules.ui",
|
|
5
5
|
"module": "expo.modules.ui",
|
|
6
|
-
"version": "57.0.
|
|
6
|
+
"version": "57.0.21",
|
|
7
7
|
"attributes": {
|
|
8
8
|
"org.gradle.status": "release"
|
|
9
9
|
}
|
|
@@ -24,13 +24,13 @@
|
|
|
24
24
|
},
|
|
25
25
|
"files": [
|
|
26
26
|
{
|
|
27
|
-
"name": "expo.modules.ui-57.0.
|
|
28
|
-
"url": "expo.modules.ui-57.0.
|
|
29
|
-
"size":
|
|
30
|
-
"sha512": "
|
|
31
|
-
"sha256": "
|
|
32
|
-
"sha1": "
|
|
33
|
-
"md5": "
|
|
27
|
+
"name": "expo.modules.ui-57.0.21.aar",
|
|
28
|
+
"url": "expo.modules.ui-57.0.21.aar",
|
|
29
|
+
"size": 2074203,
|
|
30
|
+
"sha512": "894745399f2255f02b84f664c1e62ab66d71daf4a24e3ce48ecfb7e60d0ba9abfbe31a5d9517953e2d365b786ba9da8ba8f476361777fd57006eb7fb7522c32c",
|
|
31
|
+
"sha256": "edfc30f6ff0935cee758638ea4443ec247e3628ba4a088f44f58becfca185b6e",
|
|
32
|
+
"sha1": "b8495e88a2dd3b3386885867acede44c5a99186f",
|
|
33
|
+
"md5": "8b8ece627534269af4e6dfa665f46f6c"
|
|
34
34
|
}
|
|
35
35
|
]
|
|
36
36
|
},
|
|
@@ -141,13 +141,13 @@
|
|
|
141
141
|
],
|
|
142
142
|
"files": [
|
|
143
143
|
{
|
|
144
|
-
"name": "expo.modules.ui-57.0.
|
|
145
|
-
"url": "expo.modules.ui-57.0.
|
|
146
|
-
"size":
|
|
147
|
-
"sha512": "
|
|
148
|
-
"sha256": "
|
|
149
|
-
"sha1": "
|
|
150
|
-
"md5": "
|
|
144
|
+
"name": "expo.modules.ui-57.0.21.aar",
|
|
145
|
+
"url": "expo.modules.ui-57.0.21.aar",
|
|
146
|
+
"size": 2074203,
|
|
147
|
+
"sha512": "894745399f2255f02b84f664c1e62ab66d71daf4a24e3ce48ecfb7e60d0ba9abfbe31a5d9517953e2d365b786ba9da8ba8f476361777fd57006eb7fb7522c32c",
|
|
148
|
+
"sha256": "edfc30f6ff0935cee758638ea4443ec247e3628ba4a088f44f58becfca185b6e",
|
|
149
|
+
"sha1": "b8495e88a2dd3b3386885867acede44c5a99186f",
|
|
150
|
+
"md5": "8b8ece627534269af4e6dfa665f46f6c"
|
|
151
151
|
}
|
|
152
152
|
]
|
|
153
153
|
},
|
|
@@ -161,13 +161,13 @@
|
|
|
161
161
|
},
|
|
162
162
|
"files": [
|
|
163
163
|
{
|
|
164
|
-
"name": "expo.modules.ui-57.0.
|
|
165
|
-
"url": "expo.modules.ui-57.0.
|
|
166
|
-
"size":
|
|
167
|
-
"sha512": "
|
|
168
|
-
"sha256": "
|
|
169
|
-
"sha1": "
|
|
170
|
-
"md5": "
|
|
164
|
+
"name": "expo.modules.ui-57.0.21-sources.jar",
|
|
165
|
+
"url": "expo.modules.ui-57.0.21-sources.jar",
|
|
166
|
+
"size": 105285,
|
|
167
|
+
"sha512": "bd014a7ec6f4940b753de1ef54b686c8316d45a4242893e9a508948dd22fc893063a285538d30a3fa943deedbf32915697892ff4a739e17fcb2b194a79f71d8d",
|
|
168
|
+
"sha256": "352b556c7e482ce79471552b5d73a5f29d92e9a339fd3edecf327c7df9e6576b",
|
|
169
|
+
"sha1": "ca977e2408458c690c3555514485a6a8e7fade24",
|
|
170
|
+
"md5": "711eb23ebb503bc13f871f580afcbcf0"
|
|
171
171
|
}
|
|
172
172
|
]
|
|
173
173
|
}
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.module.md5
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
a5706a2e8aab8764ef08bf740f0a7fdb
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.module.sha1
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
6cf7f09b53eaeeca0883ac8ad938b9df0e00096c
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
47ec6c69bad894a590e872629d8952ffee42b2546379499696f1ea119ccbd85a
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
84201e84b7b47e73be1a36b5223ddee0195e4c3f3c4fe038d1037befaab65ad7d397e1788f527fb81e7a6c988877c2d555d56f67cba059890af11a5e43d1851c
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
<modelVersion>4.0.0</modelVersion>
|
|
10
10
|
<groupId>expo.modules.ui</groupId>
|
|
11
11
|
<artifactId>expo.modules.ui</artifactId>
|
|
12
|
-
<version>57.0.
|
|
12
|
+
<version>57.0.21</version>
|
|
13
13
|
<packaging>aar</packaging>
|
|
14
14
|
<name>expo.modules.ui</name>
|
|
15
15
|
<url>https://github.com/expo/expo</url>
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.pom.md5
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
e7cc9d63d23c9bd704ba184dd8400433
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.pom.sha1
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
f458817401652c83a6bea14ae3809f6fbed2c4ea
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.pom.sha256
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
6d17e36602db105406e27bf20b375ca7024d6e0d66edb58aa53ba699e08a4627
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.21/expo.modules.ui-57.0.21.pom.sha512
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
76428b808dc49f9b22d89e130b22b6333b1c067da971d6bad98c113733184bb79db86721c06f52d926d31b048bc2413cc2608d7be59ad025a0bf30c5089e4ec4
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
<groupId>expo.modules.ui</groupId>
|
|
4
4
|
<artifactId>expo.modules.ui</artifactId>
|
|
5
5
|
<versioning>
|
|
6
|
-
<latest>57.0.
|
|
7
|
-
<release>57.0.
|
|
6
|
+
<latest>57.0.21</latest>
|
|
7
|
+
<release>57.0.21</release>
|
|
8
8
|
<versions>
|
|
9
|
-
<version>57.0.
|
|
9
|
+
<version>57.0.21</version>
|
|
10
10
|
</versions>
|
|
11
|
-
<lastUpdated>
|
|
11
|
+
<lastUpdated>20260929104945</lastUpdated>
|
|
12
12
|
</versioning>
|
|
13
13
|
</metadata>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
d9951eb0ffdbd1f3b4e8c66a9506881d
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
ee273f19364a6847e08cbe5eb1b5daadf787040f
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
950f75c93b0ef32cc69e20471f3a68ac9088427130a66ded938e0c3ded940478
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
ecc49926b4fd4296bc3b844a0f9a313ef93474eeb921d900d082366cb28c80c466c6dc4c5fa1b3445072b1e1bedb4b8cdf62022039209423a27b5d5c9a381a3e
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@expo/ui",
|
|
3
|
-
"version": "57.0.
|
|
3
|
+
"version": "57.0.21",
|
|
4
4
|
"description": "A collection of UI components",
|
|
5
5
|
"sideEffects": [
|
|
6
6
|
"*.fx.js",
|
|
@@ -96,8 +96,8 @@
|
|
|
96
96
|
"@types/react": "~19.2.0",
|
|
97
97
|
"react-native-reanimated": "4.5.1",
|
|
98
98
|
"react-native-worklets": "0.10.1",
|
|
99
|
-
"expo": "
|
|
100
|
-
"expo
|
|
99
|
+
"expo-module-scripts": "56.0.3",
|
|
100
|
+
"expo": "57.0.26"
|
|
101
101
|
},
|
|
102
102
|
"jest": {
|
|
103
103
|
"preset": "expo-module-scripts"
|
|
@@ -121,7 +121,7 @@
|
|
|
121
121
|
"optional": true
|
|
122
122
|
}
|
|
123
123
|
},
|
|
124
|
-
"gitHead": "
|
|
124
|
+
"gitHead": "ad1efa3fa5802156660198ba5d787f91014d8df3",
|
|
125
125
|
"scripts": {
|
|
126
126
|
"build": "expo-module build",
|
|
127
127
|
"clean": "expo-module clean",
|
|
@@ -183,11 +183,33 @@ export const isDynamicColorAvailable: boolean = ExpoUIModule.isDynamicColorAvail
|
|
|
183
183
|
*/
|
|
184
184
|
export const HostPaletteContext = createContext<MaterialColors | null>(null);
|
|
185
185
|
|
|
186
|
+
// Cache the `scheme` + `seedColor` keyed palette to prevent sync calls to `getMaterialColors`.
|
|
187
|
+
// https://github.com/expo/expo/issues/50477
|
|
188
|
+
const seededPalettes = new Map<string, MaterialColors>();
|
|
189
|
+
const MAX_SEEDED_PALETTES = 32;
|
|
190
|
+
|
|
186
191
|
/**
|
|
187
192
|
* Get the Material 3 color palette.
|
|
188
193
|
*/
|
|
189
194
|
export function getMaterialColors(options?: MaterialColorsOptions): MaterialColors {
|
|
190
|
-
|
|
195
|
+
const scheme = options?.scheme;
|
|
196
|
+
const seedColor = options?.seedColor;
|
|
197
|
+
const isCacheable =
|
|
198
|
+
(scheme === 'light' || scheme === 'dark') &&
|
|
199
|
+
(typeof seedColor === 'string' || typeof seedColor === 'number');
|
|
200
|
+
if (!isCacheable) {
|
|
201
|
+
return ExpoUIModule.getMaterialColors(options ?? null);
|
|
202
|
+
}
|
|
203
|
+
const key = `${scheme}:${seedColor}`;
|
|
204
|
+
let palette = seededPalettes.get(key);
|
|
205
|
+
if (!palette) {
|
|
206
|
+
palette = ExpoUIModule.getMaterialColors(options) as MaterialColors;
|
|
207
|
+
if (seededPalettes.size >= MAX_SEEDED_PALETTES) {
|
|
208
|
+
seededPalettes.delete(seededPalettes.keys().next().value!);
|
|
209
|
+
}
|
|
210
|
+
seededPalettes.set(key, palette);
|
|
211
|
+
}
|
|
212
|
+
return palette;
|
|
191
213
|
}
|
|
192
214
|
|
|
193
215
|
/**
|
|
@@ -443,10 +443,25 @@ export const onGloballyPositioned = (
|
|
|
443
443
|
*/
|
|
444
444
|
export const testID = (tag: string) => createModifier('testID', { testID: tag });
|
|
445
445
|
|
|
446
|
+
/**
|
|
447
|
+
* Options for the `semantics` modifier.
|
|
448
|
+
*/
|
|
449
|
+
export type SemanticsConfig = {
|
|
450
|
+
/**
|
|
451
|
+
* An autofill hint, such as `'email'` or `'password'`.
|
|
452
|
+
*/
|
|
453
|
+
contentType?: string;
|
|
454
|
+
/**
|
|
455
|
+
* What accessibility services such as TalkBack announce for the element. Useful when the visible
|
|
456
|
+
* content does not read well aloud, as with an abbreviation or a glyph.
|
|
457
|
+
*/
|
|
458
|
+
contentDescription?: string;
|
|
459
|
+
};
|
|
460
|
+
|
|
446
461
|
/**
|
|
447
462
|
* Applies semantic properties. Wraps `Modifier.semantics { ... }`.
|
|
448
463
|
*/
|
|
449
|
-
export const semantics = (params:
|
|
464
|
+
export const semantics = (params: SemanticsConfig) => createModifier('semantics', params);
|
|
450
465
|
|
|
451
466
|
// =============================================================================
|
|
452
467
|
// Clip Modifier & Shapes
|