@expo/ui 57.0.15 → 57.0.17
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 +30 -0
- package/android/build.gradle +2 -2
- package/android/src/main/java/expo/modules/ui/DatePickerView.kt +29 -18
- package/android/src/main/java/expo/modules/ui/DateRangePickerView.kt +191 -0
- package/android/src/main/java/expo/modules/ui/ExpoUIModule.kt +25 -0
- package/android/src/main/java/expo/modules/ui/HostView.kt +8 -1
- package/android/src/main/java/expo/modules/ui/RadioButtonView.kt +23 -1
- package/android/src/main/java/expo/modules/ui/VerticalSliderView.kt +145 -0
- package/android/src/main/java/expo/modules/ui/textfield/BasicTextField.kt +2 -0
- package/build/community/bottom-sheet/BottomSheet.android.d.ts.map +1 -1
- package/build/community/bottom-sheet/BottomSheet.ios.d.ts.map +1 -1
- package/build/jetpack-compose/DatePicker/index.d.ts +84 -0
- package/build/jetpack-compose/DatePicker/index.d.ts.map +1 -1
- package/build/jetpack-compose/RadioButton/index.d.ts +19 -0
- package/build/jetpack-compose/RadioButton/index.d.ts.map +1 -1
- package/build/jetpack-compose/Slider/index.d.ts +21 -0
- package/build/jetpack-compose/Slider/index.d.ts.map +1 -1
- package/build/swift-ui/modifiers/background.d.ts +32 -5
- package/build/swift-ui/modifiers/background.d.ts.map +1 -1
- package/build/swift-ui/modifiers/containerBackground.d.ts +9 -4
- package/build/swift-ui/modifiers/containerBackground.d.ts.map +1 -1
- package/build/swift-ui/modifiers/index.d.ts +45 -10
- package/build/swift-ui/modifiers/index.d.ts.map +1 -1
- package/build/swift-ui/modifiers/presentationModifiers.d.ts +6 -3
- package/build/swift-ui/modifiers/presentationModifiers.d.ts.map +1 -1
- package/expo-module.config.json +1 -1
- package/ios/Modifiers/BackgroundModifier.swift +10 -10
- package/ios/Modifiers/ContainerBackgroundModifier.swift +4 -4
- package/ios/Modifiers/PresentationModifiers.swift +3 -3
- package/ios/Modifiers/ScrollClipDisabledModifier.swift +16 -0
- package/ios/Modifiers/ViewModifierRegistry.swift +18 -8
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/{57.0.15/expo.modules.ui-57.0.15-sources.jar → 57.0.17/expo.modules.ui-57.0.17-sources.jar} +0 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17-sources.jar.md5 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17-sources.jar.sha1 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17-sources.jar.sha256 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17-sources.jar.sha512 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar +0 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar.md5 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar.sha1 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar.sha256 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar.sha512 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/{57.0.15/expo.modules.ui-57.0.15.module → 57.0.17/expo.modules.ui-57.0.17.module} +22 -22
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.module.md5 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.module.sha1 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.module.sha256 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.module.sha512 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/{57.0.15/expo.modules.ui-57.0.15.pom → 57.0.17/expo.modules.ui-57.0.17.pom} +1 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.pom.md5 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.pom.sha1 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.pom.sha256 +1 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.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/spm.config.json +1 -1
- package/src/community/bottom-sheet/BottomSheet.android.tsx +5 -3
- package/src/community/bottom-sheet/BottomSheet.ios.tsx +4 -3
- package/src/jetpack-compose/DatePicker/index.tsx +152 -0
- package/src/jetpack-compose/RadioButton/index.tsx +20 -0
- package/src/jetpack-compose/Slider/index.tsx +33 -2
- package/src/swift-ui/modifiers/background.ts +49 -7
- package/src/swift-ui/modifiers/containerBackground.ts +10 -5
- package/src/swift-ui/modifiers/index.ts +62 -8
- package/src/swift-ui/modifiers/presentationModifiers.ts +7 -4
- package/src/universal/transformStyle.ios.ts +2 -2
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15-sources.jar.md5 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15-sources.jar.sha1 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15-sources.jar.sha256 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15-sources.jar.sha512 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.aar +0 -0
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.aar.md5 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.aar.sha1 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.aar.sha256 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.aar.sha512 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.module.md5 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.module.sha1 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.module.sha256 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.module.sha512 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.pom.md5 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.pom.sha1 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.pom.sha256 +0 -1
- package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.15/expo.modules.ui-57.0.15.pom.sha512 +0 -1
|
@@ -208,11 +208,11 @@ internal struct InteractiveDismissDisabledModifier: ViewModifier, Record {
|
|
|
208
208
|
// MARK: - Presentation Background
|
|
209
209
|
|
|
210
210
|
internal struct PresentationBackgroundModifier: ViewModifier, Record {
|
|
211
|
-
@Field var
|
|
211
|
+
@Field var style: ShapeStyleValue?
|
|
212
212
|
|
|
213
213
|
func body(content: Content) -> some View {
|
|
214
|
-
if
|
|
215
|
-
content.presentationBackground(
|
|
214
|
+
if let shapeStyle = style?.toAnyShapeStyle() {
|
|
215
|
+
content.presentationBackground(shapeStyle)
|
|
216
216
|
} else {
|
|
217
217
|
content
|
|
218
218
|
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// Copyright 2015-present 650 Industries. All rights reserved.
|
|
2
|
+
|
|
3
|
+
import ExpoModulesCore
|
|
4
|
+
import SwiftUI
|
|
5
|
+
|
|
6
|
+
internal struct ScrollClipDisabledModifier: ViewModifier, Record {
|
|
7
|
+
@Field var disabled: Bool = true
|
|
8
|
+
|
|
9
|
+
func body(content: Content) -> some View {
|
|
10
|
+
if #available(iOS 17.0, tvOS 17.0, *) {
|
|
11
|
+
content.scrollClipDisabled(disabled)
|
|
12
|
+
} else {
|
|
13
|
+
content
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -231,11 +231,11 @@ internal struct MonospacedDigitModifier: ViewModifier, Record {
|
|
|
231
231
|
}
|
|
232
232
|
|
|
233
233
|
internal struct TintModifier: ViewModifier, Record {
|
|
234
|
-
@Field var
|
|
234
|
+
@Field var tint: ShapeStyleValue?
|
|
235
235
|
|
|
236
236
|
func body(content: Content) -> some View {
|
|
237
|
-
if let
|
|
238
|
-
content.tint(
|
|
237
|
+
if let shapeStyle = tint?.toAnyShapeStyle() {
|
|
238
|
+
content.tint(shapeStyle)
|
|
239
239
|
} else {
|
|
240
240
|
content
|
|
241
241
|
}
|
|
@@ -384,11 +384,16 @@ internal struct GrayscaleModifier: ViewModifier, Record {
|
|
|
384
384
|
}
|
|
385
385
|
|
|
386
386
|
internal struct BorderModifier: ViewModifier, Record {
|
|
387
|
-
|
|
387
|
+
// Declared as `shapeStyle` because `content` is taken by the parameter of `body(content:)`.
|
|
388
|
+
@Field("content") var shapeStyle: ShapeStyleValue?
|
|
388
389
|
@Field var width: CGFloat = 1.0
|
|
389
390
|
|
|
390
391
|
func body(content: Content) -> some View {
|
|
391
|
-
|
|
392
|
+
if let resolvedStyle = shapeStyle?.toAnyShapeStyle() {
|
|
393
|
+
content.border(resolvedStyle, width: width)
|
|
394
|
+
} else {
|
|
395
|
+
content
|
|
396
|
+
}
|
|
392
397
|
}
|
|
393
398
|
}
|
|
394
399
|
|
|
@@ -418,7 +423,8 @@ internal struct ClipShapeModifier: ViewModifier, Record {
|
|
|
418
423
|
}
|
|
419
424
|
|
|
420
425
|
internal struct StrokeBorderModifier: ViewModifier, Record {
|
|
421
|
-
|
|
426
|
+
// Declared as `shapeStyle` because `content` is taken by the parameter of `body(content:)`.
|
|
427
|
+
@Field("content") var shapeStyle: ShapeStyleValue?
|
|
422
428
|
@Field var style: StrokeStyleConfig?
|
|
423
429
|
@Field var antialiased: Bool = true
|
|
424
430
|
@Field var shape: ShapeType = .rectangle
|
|
@@ -451,8 +457,8 @@ internal struct StrokeBorderModifier: ViewModifier, Record {
|
|
|
451
457
|
|
|
452
458
|
@ViewBuilder
|
|
453
459
|
private func applyStrokeBorder<S: InsettableShape>(_ shape: S, _ strokeStyle: StrokeStyle) -> some View {
|
|
454
|
-
if let
|
|
455
|
-
shape.strokeBorder(
|
|
460
|
+
if let resolvedStyle = shapeStyle?.toAnyShapeStyle() {
|
|
461
|
+
shape.strokeBorder(resolvedStyle, style: strokeStyle, antialiased: antialiased)
|
|
456
462
|
} else {
|
|
457
463
|
shape.strokeBorder(style: strokeStyle, antialiased: antialiased)
|
|
458
464
|
}
|
|
@@ -2274,6 +2280,10 @@ extension ViewModifierRegistry {
|
|
|
2274
2280
|
return try ScrollDisabledModifier(from: params, appContext: appContext)
|
|
2275
2281
|
}
|
|
2276
2282
|
|
|
2283
|
+
register("scrollClipDisabled") { params, appContext, _ in
|
|
2284
|
+
return try ScrollClipDisabledModifier(from: params, appContext: appContext)
|
|
2285
|
+
}
|
|
2286
|
+
|
|
2277
2287
|
register("scrollIndicators") { params, appContext, _ in
|
|
2278
2288
|
return try ScrollIndicatorsModifier(from: params, appContext: appContext)
|
|
2279
2289
|
}
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
cee93fd5a15e4eaab695ed3175a4949f
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
43ac02b43fa332c84dbd29354a8ffc002828927a
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
a2eb95b5f7bc80a8406159f0cd3cc67058927f3e88d1ce5e0eed1000f47bf6e7
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
6a46b6260033cfdf2fcb8cb69b966ac7dcca618a6f3e9c011819a76e42f998c2a549b1864bbbbd642b106c01d9ee184eb822019cc58d4b438103ed8d421cbb2d
|
|
Binary file
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar.md5
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
87a5f6dc53fef1a3b6810eb8db0ccc6a
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar.sha1
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
394fabe7251e3d947f0bbf2037e2bb065b8493d5
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar.sha256
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
13b9babd2eaa4ed0f4ad6a09f8443eb1a4bca31cc519d29db8371cdabd6487e4
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.aar.sha512
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
10a5b1af451aa49760a4c2ca23f439feeff3ee645cef0ca3af0ef7e487efeb5d26c3ff608ce68568a005f46707a5b774e274b5ca0ffc058429d633e600c9ed1e
|
|
@@ -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.17",
|
|
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.17.aar",
|
|
28
|
+
"url": "expo.modules.ui-57.0.17.aar",
|
|
29
|
+
"size": 2072906,
|
|
30
|
+
"sha512": "10a5b1af451aa49760a4c2ca23f439feeff3ee645cef0ca3af0ef7e487efeb5d26c3ff608ce68568a005f46707a5b774e274b5ca0ffc058429d633e600c9ed1e",
|
|
31
|
+
"sha256": "13b9babd2eaa4ed0f4ad6a09f8443eb1a4bca31cc519d29db8371cdabd6487e4",
|
|
32
|
+
"sha1": "394fabe7251e3d947f0bbf2037e2bb065b8493d5",
|
|
33
|
+
"md5": "87a5f6dc53fef1a3b6810eb8db0ccc6a"
|
|
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.17.aar",
|
|
145
|
+
"url": "expo.modules.ui-57.0.17.aar",
|
|
146
|
+
"size": 2072906,
|
|
147
|
+
"sha512": "10a5b1af451aa49760a4c2ca23f439feeff3ee645cef0ca3af0ef7e487efeb5d26c3ff608ce68568a005f46707a5b774e274b5ca0ffc058429d633e600c9ed1e",
|
|
148
|
+
"sha256": "13b9babd2eaa4ed0f4ad6a09f8443eb1a4bca31cc519d29db8371cdabd6487e4",
|
|
149
|
+
"sha1": "394fabe7251e3d947f0bbf2037e2bb065b8493d5",
|
|
150
|
+
"md5": "87a5f6dc53fef1a3b6810eb8db0ccc6a"
|
|
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.17-sources.jar",
|
|
165
|
+
"url": "expo.modules.ui-57.0.17-sources.jar",
|
|
166
|
+
"size": 105126,
|
|
167
|
+
"sha512": "6a46b6260033cfdf2fcb8cb69b966ac7dcca618a6f3e9c011819a76e42f998c2a549b1864bbbbd642b106c01d9ee184eb822019cc58d4b438103ed8d421cbb2d",
|
|
168
|
+
"sha256": "a2eb95b5f7bc80a8406159f0cd3cc67058927f3e88d1ce5e0eed1000f47bf6e7",
|
|
169
|
+
"sha1": "43ac02b43fa332c84dbd29354a8ffc002828927a",
|
|
170
|
+
"md5": "cee93fd5a15e4eaab695ed3175a4949f"
|
|
171
171
|
}
|
|
172
172
|
]
|
|
173
173
|
}
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.module.md5
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
5cdd34e3be888a5735c256250dd728cf
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.module.sha1
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
b7846d058304cfb924196deafc5d6e30418c63cd
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3ce103a426470ca2198f1231ebd5030611bcbd360a51bc830b48dcc7ad7853f2
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
6c831b75309aa91c19aec99702afc5ce461d7fdd215d6acf9565429437744faf0ecc2b953f82fde708241646797dbd4adf9b47f6dc07b388e6179dd0ad4341e7
|
|
@@ -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.17</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.17/expo.modules.ui-57.0.17.pom.md5
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
edd1385c2afe1e6a5c4974dfc1d3b6b8
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.pom.sha1
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
8ec443820fac6b3c0527234e124be03c815e81d0
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.pom.sha256
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
68858cf5c7e2ff60833e8e6d3c4c5f1683969c7d5f24965470e431605eaa1f70
|
package/local-maven-repo/expo/modules/ui/expo.modules.ui/57.0.17/expo.modules.ui-57.0.17.pom.sha512
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
637e334e0226ffefc9abe120e7c35fe3441432d6fe47bd1c0dff56445168808763dca58272af02d7af20442213088b037129ff8bff12ce37640a1ad88a13c4d7
|
|
@@ -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.17</latest>
|
|
7
|
+
<release>57.0.17</release>
|
|
8
8
|
<versions>
|
|
9
|
-
<version>57.0.
|
|
9
|
+
<version>57.0.17</version>
|
|
10
10
|
</versions>
|
|
11
|
-
<lastUpdated>
|
|
11
|
+
<lastUpdated>20260908134223</lastUpdated>
|
|
12
12
|
</versioning>
|
|
13
13
|
</metadata>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
dd7d18bde7636ea29ab7549373c2f43a
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
d491c408ce08119efc695fac8f3abe210c89b66a
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
f6eeadee99bcfa2fce76c19ec4942a74b7323cddef420a50177b3ddaf7a0a699
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
7b2b797876e13355724bf86b591ebc3bd278cbb4c6c80b55ee5bd5cc80dcd174e67f5f1ff6c9d9901bcf5042799520c481924e8dad2e672b71ca7912db357f1a
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@expo/ui",
|
|
3
|
-
"version": "57.0.
|
|
3
|
+
"version": "57.0.17",
|
|
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": "57.0.21",
|
|
100
|
+
"expo-module-scripts": "56.0.3"
|
|
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": "ee89f7c31877f111cb1705c8e5c2c8078fa80a03",
|
|
125
125
|
"scripts": {
|
|
126
126
|
"build": "expo-module build",
|
|
127
127
|
"clean": "expo-module clean",
|
package/spm.config.json
CHANGED
|
@@ -200,9 +200,11 @@ export function BottomSheet(props: BottomSheetProps) {
|
|
|
200
200
|
shouldDismissOnClickOutside: enablePanDownToClose,
|
|
201
201
|
}}>
|
|
202
202
|
<RNHostView matchContents={fitToContents}>
|
|
203
|
-
{/*
|
|
204
|
-
|
|
205
|
-
|
|
203
|
+
{/* With matchContents, RNHostView lays the hosted view out at its own size, so `width` gives it
|
|
204
|
+
the sheet width while its height stays content-sized. Otherwise flexGrow:1 + height:0
|
|
205
|
+
(flex-basis 0) fills RNHostView's measured height without inheriting the scrollable
|
|
206
|
+
child's content height, which would block scrolling to the end. */}
|
|
207
|
+
<View style={fitToContents ? { width } : { flexGrow: 1, height: 0 }}>
|
|
206
208
|
<SheetScrollContextReset>{children}</SheetScrollContextReset>
|
|
207
209
|
</View>
|
|
208
210
|
</RNHostView>
|
|
@@ -234,12 +234,13 @@ export function BottomSheet(props: BottomSheetProps) {
|
|
|
234
234
|
<RNHostView matchContents={fitToContents}>
|
|
235
235
|
{/* paddingTop compensates for tighter spacing between native drag indicator and content
|
|
236
236
|
compared to gorhom's handle. flexGrow:1 + height:0 (flex-basis 0) fills the snap-point
|
|
237
|
-
height without inheriting the scrollable child's intrinsic content height.
|
|
238
|
-
so
|
|
237
|
+
height without inheriting the scrollable child's intrinsic content height. With matchContents,
|
|
238
|
+
RNHostView lays the hosted view out at its own size, so `width` gives it the sheet width
|
|
239
|
+
while its height stays content-sized. */}
|
|
239
240
|
<View
|
|
240
241
|
style={
|
|
241
242
|
fitToContents
|
|
242
|
-
? { paddingTop: handleComponent !== null ? 16 : 0 }
|
|
243
|
+
? { width, paddingTop: handleComponent !== null ? 16 : 0 }
|
|
243
244
|
: { flexGrow: 1, height: 0, paddingTop: handleComponent !== null ? 16 : 0 }
|
|
244
245
|
}>
|
|
245
246
|
<SheetScrollContextReset>{children}</SheetScrollContextReset>
|
|
@@ -8,6 +8,20 @@ export type AndroidVariant = 'picker' | 'input';
|
|
|
8
8
|
|
|
9
9
|
export type DisplayedComponents = 'date' | 'hourAndMinute' | 'dateAndTime';
|
|
10
10
|
|
|
11
|
+
/**
|
|
12
|
+
* The date range reported by `DateRangePicker` and `DateRangePickerDialog`.
|
|
13
|
+
*/
|
|
14
|
+
export type DateRangeSelection = {
|
|
15
|
+
/**
|
|
16
|
+
* The selected start date, or `null` when no start date is selected.
|
|
17
|
+
*/
|
|
18
|
+
start: Date | null;
|
|
19
|
+
/**
|
|
20
|
+
* The selected end date, or `null` until the user selects the second date of the range.
|
|
21
|
+
*/
|
|
22
|
+
end: Date | null;
|
|
23
|
+
};
|
|
24
|
+
|
|
11
25
|
/**
|
|
12
26
|
* Color overrides for the Material 3 DatePicker component.
|
|
13
27
|
* All properties are optional — unset values use Material 3 theme defaults.
|
|
@@ -177,6 +191,10 @@ function convertSelectableDates(selectableDates?: {
|
|
|
177
191
|
};
|
|
178
192
|
}
|
|
179
193
|
|
|
194
|
+
function convertTimestampToDate(timestamp: number | null): Date | null {
|
|
195
|
+
return timestamp == null ? null : new Date(timestamp);
|
|
196
|
+
}
|
|
197
|
+
|
|
180
198
|
function transformDateTimePickerProps(props: DateTimePickerProps): NativeDatePickerProps {
|
|
181
199
|
const { modifiers, variant, initialDate, selectableDates, elementColors, color, ...rest } = props;
|
|
182
200
|
|
|
@@ -210,6 +228,100 @@ export function DateTimePicker(props: DateTimePickerProps) {
|
|
|
210
228
|
return <DatePickerNativeView {...transformDateTimePickerProps(props)} />;
|
|
211
229
|
}
|
|
212
230
|
|
|
231
|
+
export interface DateRangePickerProps {
|
|
232
|
+
/**
|
|
233
|
+
* The initially selected start date, as an ISO 8601 string.
|
|
234
|
+
*/
|
|
235
|
+
initialStartDate?: string | null;
|
|
236
|
+
/**
|
|
237
|
+
* The initially selected end date, as an ISO 8601 string. It must be on or after `initialStartDate`.
|
|
238
|
+
*/
|
|
239
|
+
initialEndDate?: string | null;
|
|
240
|
+
/**
|
|
241
|
+
* Called once when the component mounts with the initial range, and again whenever the selected date range changes.
|
|
242
|
+
* The end date is `null` while the user is selecting a range.
|
|
243
|
+
*/
|
|
244
|
+
onDateRangeSelected?: (range: DateRangeSelection) => void;
|
|
245
|
+
/**
|
|
246
|
+
* The variant of the picker, which determines its appearance and behavior.
|
|
247
|
+
* @default 'picker'
|
|
248
|
+
*/
|
|
249
|
+
variant?: AndroidVariant;
|
|
250
|
+
/**
|
|
251
|
+
* Show a button to toggle between variants on Android.
|
|
252
|
+
* @default true
|
|
253
|
+
*/
|
|
254
|
+
showVariantToggle?: boolean;
|
|
255
|
+
/**
|
|
256
|
+
* The tint color to use on the picker elements.
|
|
257
|
+
*/
|
|
258
|
+
color?: ColorValue;
|
|
259
|
+
/**
|
|
260
|
+
* Fine-grained color overrides for individual picker elements.
|
|
261
|
+
*/
|
|
262
|
+
elementColors?: DatePickerElementColors;
|
|
263
|
+
/**
|
|
264
|
+
* Constrains which dates can be selected. `start` is the earliest selectable date and `end` is
|
|
265
|
+
* the latest.
|
|
266
|
+
*/
|
|
267
|
+
selectableDates?: { start?: Date; end?: Date };
|
|
268
|
+
/**
|
|
269
|
+
* Modifiers for the component.
|
|
270
|
+
*/
|
|
271
|
+
modifiers?: ModifierConfig[];
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
type NativeDateRangePickerProps = Omit<
|
|
275
|
+
DateRangePickerProps,
|
|
276
|
+
'onDateRangeSelected' | 'initialStartDate' | 'initialEndDate' | 'selectableDates'
|
|
277
|
+
> & {
|
|
278
|
+
initialStartDate?: number | null;
|
|
279
|
+
initialEndDate?: number | null;
|
|
280
|
+
selectableDates?: { start?: number | null; end?: number | null } | null;
|
|
281
|
+
} & ViewEvent<'onDateRangeSelected', { start: number | null; end: number | null }>;
|
|
282
|
+
|
|
283
|
+
function transformDateRangePickerProps(
|
|
284
|
+
props: Omit<DateRangePickerProps, 'modifiers'>
|
|
285
|
+
): Omit<NativeDateRangePickerProps, 'modifiers'> {
|
|
286
|
+
const {
|
|
287
|
+
initialStartDate,
|
|
288
|
+
initialEndDate,
|
|
289
|
+
selectableDates,
|
|
290
|
+
elementColors,
|
|
291
|
+
onDateRangeSelected,
|
|
292
|
+
...rest
|
|
293
|
+
} = props;
|
|
294
|
+
return {
|
|
295
|
+
...rest,
|
|
296
|
+
initialStartDate: initialStartDate ? new Date(initialStartDate).getTime() : null,
|
|
297
|
+
initialEndDate: initialEndDate ? new Date(initialEndDate).getTime() : null,
|
|
298
|
+
selectableDates: convertSelectableDates(selectableDates),
|
|
299
|
+
onDateRangeSelected: ({ nativeEvent: { start, end } }) => {
|
|
300
|
+
onDateRangeSelected?.({
|
|
301
|
+
start: convertTimestampToDate(start),
|
|
302
|
+
end: convertTimestampToDate(end),
|
|
303
|
+
});
|
|
304
|
+
},
|
|
305
|
+
...(elementColors != null ? { elementColors } : undefined),
|
|
306
|
+
};
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
const DateRangePickerNativeView: React.ComponentType<NativeDateRangePickerProps> =
|
|
310
|
+
requireNativeView('ExpoUI', 'DateRangePickerView');
|
|
311
|
+
|
|
312
|
+
/**
|
|
313
|
+
* Renders an inline Material 3 date range picker.
|
|
314
|
+
*/
|
|
315
|
+
export function DateRangePicker(props: DateRangePickerProps) {
|
|
316
|
+
const { modifiers, ...rest } = props;
|
|
317
|
+
const nativeProps: NativeDateRangePickerProps = {
|
|
318
|
+
modifiers,
|
|
319
|
+
...(modifiers ? createViewModifierEventListener(modifiers) : undefined),
|
|
320
|
+
...transformDateRangePickerProps(rest),
|
|
321
|
+
};
|
|
322
|
+
return <DateRangePickerNativeView {...nativeProps} />;
|
|
323
|
+
}
|
|
324
|
+
|
|
213
325
|
// -- Dialog views (used internally by the compat layer) ---------------------
|
|
214
326
|
|
|
215
327
|
export interface DatePickerDialogProps {
|
|
@@ -260,6 +372,46 @@ export function DatePickerDialog(props: DatePickerDialogProps) {
|
|
|
260
372
|
return <DatePickerDialogNativeView {...nativeProps} />;
|
|
261
373
|
}
|
|
262
374
|
|
|
375
|
+
export interface DateRangePickerDialogProps extends Omit<DateRangePickerProps, 'modifiers'> {
|
|
376
|
+
/**
|
|
377
|
+
* The label for the button that confirms the selected range.
|
|
378
|
+
* Defaults to the system "Ok" string.
|
|
379
|
+
*/
|
|
380
|
+
confirmButtonLabel?: string;
|
|
381
|
+
/**
|
|
382
|
+
* The label for the button that dismisses the dialog.
|
|
383
|
+
* Defaults to the system "Cancel" string.
|
|
384
|
+
*/
|
|
385
|
+
dismissButtonLabel?: string;
|
|
386
|
+
/** The tint color to use on the picker elements and dialog buttons. */
|
|
387
|
+
color?: ColorValue;
|
|
388
|
+
/** Callback function that is called when the user confirms a complete date range. */
|
|
389
|
+
onDateRangeSelected?: (range: DateRangeSelection) => void;
|
|
390
|
+
/** Callback function that is called when the dialog is dismissed. */
|
|
391
|
+
onDismissRequest: () => void;
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
type NativeDateRangePickerDialogProps = Omit<NativeDateRangePickerProps, 'modifiers'> &
|
|
395
|
+
Pick<DateRangePickerDialogProps, 'confirmButtonLabel' | 'dismissButtonLabel'> &
|
|
396
|
+
ViewEvent<'onDismissRequest', void>;
|
|
397
|
+
|
|
398
|
+
const DateRangePickerDialogNativeView: React.ComponentType<NativeDateRangePickerDialogProps> =
|
|
399
|
+
requireNativeView('ExpoUI', 'DateRangePickerDialogView');
|
|
400
|
+
|
|
401
|
+
/**
|
|
402
|
+
* Renders a modal Material 3 date range picker.
|
|
403
|
+
*/
|
|
404
|
+
export function DateRangePickerDialog(props: DateRangePickerDialogProps) {
|
|
405
|
+
const { confirmButtonLabel, dismissButtonLabel, onDismissRequest, ...rest } = props;
|
|
406
|
+
const nativeProps: NativeDateRangePickerDialogProps = {
|
|
407
|
+
...transformDateRangePickerProps(rest),
|
|
408
|
+
confirmButtonLabel,
|
|
409
|
+
dismissButtonLabel,
|
|
410
|
+
onDismissRequest,
|
|
411
|
+
};
|
|
412
|
+
return <DateRangePickerDialogNativeView {...nativeProps} />;
|
|
413
|
+
}
|
|
414
|
+
|
|
263
415
|
export interface TimePickerDialogProps {
|
|
264
416
|
initialDate?: string | null;
|
|
265
417
|
is24Hour?: boolean;
|
|
@@ -1,17 +1,37 @@
|
|
|
1
1
|
import { requireNativeView } from 'expo';
|
|
2
|
+
import type { ColorValue } from 'react-native';
|
|
2
3
|
|
|
3
4
|
import { type ModifierConfig, type ViewEvent } from '../../types';
|
|
4
5
|
import { createViewModifierEventListener } from '../modifiers/utils';
|
|
5
6
|
|
|
7
|
+
/**
|
|
8
|
+
* Colors for the radio button in different states.
|
|
9
|
+
*/
|
|
10
|
+
export type RadioButtonColors = {
|
|
11
|
+
selectedColor?: ColorValue;
|
|
12
|
+
unselectedColor?: ColorValue;
|
|
13
|
+
disabledSelectedColor?: ColorValue;
|
|
14
|
+
disabledUnselectedColor?: ColorValue;
|
|
15
|
+
};
|
|
16
|
+
|
|
6
17
|
export interface RadioButtonProps {
|
|
7
18
|
/**
|
|
8
19
|
* Whether the radio button is selected.
|
|
9
20
|
*/
|
|
10
21
|
selected: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* Whether the radio button is enabled.
|
|
24
|
+
* @default true
|
|
25
|
+
*/
|
|
26
|
+
enabled?: boolean;
|
|
11
27
|
/**
|
|
12
28
|
* Callback that is called when the radio button is clicked.
|
|
13
29
|
*/
|
|
14
30
|
onClick?: () => void;
|
|
31
|
+
/**
|
|
32
|
+
* Colors for the radio button in different states.
|
|
33
|
+
*/
|
|
34
|
+
colors?: RadioButtonColors;
|
|
15
35
|
/**
|
|
16
36
|
* Modifiers for the component.
|
|
17
37
|
*/
|
|
@@ -86,6 +86,14 @@ export interface SliderProps {
|
|
|
86
86
|
children?: React.ReactNode;
|
|
87
87
|
}
|
|
88
88
|
|
|
89
|
+
export interface VerticalSliderProps extends SliderProps {
|
|
90
|
+
/**
|
|
91
|
+
* Whether the direction of the slider is reversed. By default, values increase from top to bottom.
|
|
92
|
+
* @default false
|
|
93
|
+
*/
|
|
94
|
+
reverseDirection?: boolean;
|
|
95
|
+
}
|
|
96
|
+
|
|
89
97
|
type NativeSliderProps = Omit<SliderProps, 'onValueChange' | 'onValueChangeFinished' | 'children'> &
|
|
90
98
|
ViewEvent<'onValueChange', { value: number }> &
|
|
91
99
|
ViewEvent<'onValueChangeFinished', void> & { children?: React.ReactNode };
|
|
@@ -95,6 +103,10 @@ const SliderNativeView: React.ComponentType<NativeSliderProps> = requireNativeVi
|
|
|
95
103
|
'SliderView'
|
|
96
104
|
);
|
|
97
105
|
|
|
106
|
+
const VerticalSliderNativeView: React.ComponentType<
|
|
107
|
+
NativeSliderProps & Pick<VerticalSliderProps, 'reverseDirection'>
|
|
108
|
+
> = requireNativeView('ExpoUI', 'VerticalSliderView');
|
|
109
|
+
|
|
98
110
|
function transformSliderProps(
|
|
99
111
|
props: Omit<SliderProps, 'children'>
|
|
100
112
|
): Omit<NativeSliderProps, 'children'> {
|
|
@@ -118,7 +130,7 @@ function transformSliderProps(
|
|
|
118
130
|
}
|
|
119
131
|
|
|
120
132
|
/**
|
|
121
|
-
* A custom thumb slot for `Slider`.
|
|
133
|
+
* A custom thumb slot for `Slider` and `VerticalSlider`.
|
|
122
134
|
* Wrap any content to use as the slider's thumb indicator.
|
|
123
135
|
*
|
|
124
136
|
* @platform android
|
|
@@ -128,7 +140,7 @@ function Thumb(props: { children: React.ReactNode }) {
|
|
|
128
140
|
}
|
|
129
141
|
|
|
130
142
|
/**
|
|
131
|
-
* A custom track slot for `Slider`.
|
|
143
|
+
* A custom track slot for `Slider` and `VerticalSlider`.
|
|
132
144
|
* Wrap any content to use as the slider's track.
|
|
133
145
|
*
|
|
134
146
|
* @platform android
|
|
@@ -150,4 +162,23 @@ function SliderComponent(props: SliderProps) {
|
|
|
150
162
|
SliderComponent.Thumb = Thumb;
|
|
151
163
|
SliderComponent.Track = Track;
|
|
152
164
|
|
|
165
|
+
/**
|
|
166
|
+
* A vertical slider component that wraps Material3's `VerticalSlider`.
|
|
167
|
+
*
|
|
168
|
+
* @platform android
|
|
169
|
+
*/
|
|
170
|
+
export function VerticalSlider(props: VerticalSliderProps) {
|
|
171
|
+
const { children, reverseDirection, ...sliderProps } = props;
|
|
172
|
+
return (
|
|
173
|
+
<VerticalSliderNativeView
|
|
174
|
+
{...transformSliderProps(sliderProps)}
|
|
175
|
+
reverseDirection={reverseDirection}>
|
|
176
|
+
{children}
|
|
177
|
+
</VerticalSliderNativeView>
|
|
178
|
+
);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
VerticalSlider.Thumb = Thumb;
|
|
182
|
+
VerticalSlider.Track = Track;
|
|
183
|
+
|
|
153
184
|
export { SliderComponent as Slider };
|