@expo/ui 58.0.12 → 58.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (91) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/android/build.gradle +2 -2
  3. package/android/src/main/java/expo/modules/ui/DatePickerView.kt +1 -0
  4. package/build/State/index.d.ts +1 -0
  5. package/build/State/index.js +1 -0
  6. package/build/State/index.js.map +1 -1
  7. package/build/State/useWorkletCallback.d.ts +31 -0
  8. package/build/State/useWorkletCallback.js +30 -0
  9. package/build/State/useWorkletCallback.js.map +1 -0
  10. package/build/community/datetime-picker/DateTimePicker.android.js +13 -4
  11. package/build/community/datetime-picker/DateTimePicker.android.js.map +1 -1
  12. package/build/community/datetime-picker/utils.d.ts +10 -0
  13. package/build/community/datetime-picker/utils.js +19 -0
  14. package/build/community/datetime-picker/utils.js.map +1 -0
  15. package/build/jetpack-compose/MaterialSymbolsAssetsTransformer.fx.js.map +1 -1
  16. package/build/jetpack-compose/index.d.ts +1 -1
  17. package/build/jetpack-compose/index.js +1 -1
  18. package/build/jetpack-compose/index.js.map +1 -1
  19. package/build/swift-ui/ArrangementView/index.d.ts +48 -0
  20. package/build/swift-ui/ArrangementView/index.js +56 -0
  21. package/build/swift-ui/ArrangementView/index.js.map +1 -0
  22. package/build/swift-ui/index.d.ts +2 -1
  23. package/build/swift-ui/index.js +2 -1
  24. package/build/swift-ui/index.js.map +1 -1
  25. package/build/swift-ui/modifiers/arrangementModifiers.d.ts +109 -0
  26. package/build/swift-ui/modifiers/arrangementModifiers.js +35 -0
  27. package/build/swift-ui/modifiers/arrangementModifiers.js.map +1 -0
  28. package/build/swift-ui/modifiers/hingeObservation.d.ts +73 -0
  29. package/build/swift-ui/modifiers/hingeObservation.js +45 -0
  30. package/build/swift-ui/modifiers/hingeObservation.js.map +1 -0
  31. package/build/swift-ui/modifiers/index.d.ts +4 -1
  32. package/build/swift-ui/modifiers/index.js +2 -0
  33. package/build/swift-ui/modifiers/index.js.map +1 -1
  34. package/ios/ArrangementViewView.swift +40 -0
  35. package/ios/ExpoUIModule.swift +1 -0
  36. package/ios/Modifiers/ArrangementModifiers.swift +157 -0
  37. package/ios/Modifiers/HingeObservationModifiers.swift +82 -0
  38. package/ios/Modifiers/ViewModifierRegistry.swift +28 -3
  39. package/local-maven-repo/expo/modules/ui/expo.modules.ui/{58.0.12/expo.modules.ui-58.0.12-sources.jar → 58.0.14/expo.modules.ui-58.0.14-sources.jar} +0 -0
  40. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14-sources.jar.md5 +1 -0
  41. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14-sources.jar.sha1 +1 -0
  42. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14-sources.jar.sha256 +1 -0
  43. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14-sources.jar.sha512 +1 -0
  44. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.aar +0 -0
  45. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.aar.md5 +1 -0
  46. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.aar.sha1 +1 -0
  47. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.aar.sha256 +1 -0
  48. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.aar.sha512 +1 -0
  49. package/local-maven-repo/expo/modules/ui/expo.modules.ui/{58.0.12/expo.modules.ui-58.0.12.module → 58.0.14/expo.modules.ui-58.0.14.module} +22 -22
  50. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.module.md5 +1 -0
  51. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.module.sha1 +1 -0
  52. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.module.sha256 +1 -0
  53. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.module.sha512 +1 -0
  54. package/local-maven-repo/expo/modules/ui/expo.modules.ui/{58.0.12/expo.modules.ui-58.0.12.pom → 58.0.14/expo.modules.ui-58.0.14.pom} +1 -1
  55. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.pom.md5 +1 -0
  56. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.pom.sha1 +1 -0
  57. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.pom.sha256 +1 -0
  58. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.14/expo.modules.ui-58.0.14.pom.sha512 +1 -0
  59. package/package.json +2 -2
  60. package/prebuilds/output/debug/xcframeworks/ExpoUI.tar.gz +0 -0
  61. package/prebuilds/output/release/xcframeworks/ExpoUI.tar.gz +0 -0
  62. package/src/State/index.ts +1 -0
  63. package/src/State/useWorkletCallback.ts +48 -0
  64. package/src/community/datetime-picker/DateTimePicker.android.tsx +14 -4
  65. package/src/community/datetime-picker/utils.ts +21 -0
  66. package/src/jetpack-compose/MaterialSymbolsAssetsTransformer.fx.ts +6 -2
  67. package/src/jetpack-compose/index.ts +1 -1
  68. package/src/swift-ui/ArrangementView/index.tsx +70 -0
  69. package/src/swift-ui/index.tsx +2 -1
  70. package/src/swift-ui/modifiers/arrangementModifiers.ts +142 -0
  71. package/src/swift-ui/modifiers/hingeObservation.ts +91 -0
  72. package/src/swift-ui/modifiers/index.ts +4 -0
  73. package/build/ts-declarations/react-native-assets.d.ts +0 -31
  74. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12-sources.jar.md5 +0 -1
  75. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12-sources.jar.sha1 +0 -1
  76. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12-sources.jar.sha256 +0 -1
  77. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12-sources.jar.sha512 +0 -1
  78. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.aar +0 -0
  79. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.aar.md5 +0 -1
  80. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.aar.sha1 +0 -1
  81. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.aar.sha256 +0 -1
  82. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.aar.sha512 +0 -1
  83. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.module.md5 +0 -1
  84. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.module.sha1 +0 -1
  85. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.module.sha256 +0 -1
  86. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.module.sha512 +0 -1
  87. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.pom.md5 +0 -1
  88. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.pom.sha1 +0 -1
  89. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.pom.sha256 +0 -1
  90. package/local-maven-repo/expo/modules/ui/expo.modules.ui/58.0.12/expo.modules.ui-58.0.12.pom.sha512 +0 -1
  91. package/src/ts-declarations/react-native-assets.d.ts +0 -31
package/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  # Changelog
2
2
 
3
+ ## 58.0.14
4
+
5
+ ### Patch Changes
6
+
7
+ - [Android] Fix the community `DateTimePicker` reading `value` as a UTC day while `minimumDate`/`maximumDate` use the device-local day. In non-UTC timezones the picker could select and return the wrong day — one before `minimumDate`. `value`'s local calendar day is now sent to Material3 as a UTC day, and the picked day is returned as a local date that keeps `value`'s time of day. ([#50941](https://github.com/expo/expo/pull/50941) by [@expo-bot](https://github.com/expo-bot))
8
+ - [Internal] Import React Native internals from `react-native/unstable-internals-do-not-use`. ([#50860](https://github.com/expo/expo/pull/50860) by [@huntie](https://github.com/huntie))
9
+
10
+ ## 58.0.13
11
+
12
+ ### Patch Changes
13
+
14
+ - [iOS] Add `ArrangementView` component and `arrangementViewStyle`, `splitArrangementLayoutRatio`, `splitArrangementLayoutSize`, `splitArrangementFixedLayoutSize`, and `overlayArrangementEdge` modifiers. ([#50893](https://github.com/expo/expo/pull/50893) by [@intergalacticspacehighway](https://github.com/intergalacticspacehighway))
15
+ - [Android] Fix `TimePickerDialog` ignoring `elementColors.containerColor`. ([#51116](https://github.com/expo/expo/pull/51116) by [@expo-bot](https://github.com/expo-bot))
16
+ - [iOS][tvOS] Fix the tvOS build failing to compile with `'inlineLarge' is unavailable in tvOS` when `@expo/ui` is linked. `ToolbarTitleDisplayMode.inlineLarge` is unavailable on tvOS, but the `inlineLarge` case of the `toolbarTitleDisplayMode` modifier was only gated behind an OS version check that listed `tvOS 18.0`, so it was compiled into the tvOS slice. It is now guarded by platform and returns `nil` on tvOS. The same check also required iOS 18.0 / macOS 15.0, so `inlineLarge` silently fell back to `automatic` on iOS 17 and macOS 14 even though it is available there; it now applies on those versions. ([#51007](https://github.com/expo/expo/pull/51007) by [@gabrieldonadel](https://github.com/gabrieldonadel))
17
+ - [iOS] `onHingeChange` also accepts a callback from `useWorkletCallback`, which runs on the UI thread to track the hinge angle without a JS-thread round trip. ([#50910](https://github.com/expo/expo/pull/50910) by [@huntie](https://github.com/huntie))
18
+ - [iOS] Added the `onHingeChange` modifier, which reports the device hinge angle and status on iPhone Duo (iOS 27.1+). ([#50909](https://github.com/expo/expo/pull/50909) by [@huntie](https://github.com/huntie))
19
+ - Added the `useWorkletCallback` hook, which wraps a worklet function so a modifier that accepts one can run it synchronously on the UI thread. ([#51108](https://github.com/expo/expo/pull/51108) by [@huntie](https://github.com/huntie))
20
+
3
21
  ## 58.0.12
4
22
 
5
23
  ### Patch Changes
@@ -12,13 +12,13 @@ apply plugin: 'expo-module-gradle-plugin'
12
12
  apply plugin: 'org.jetbrains.kotlin.plugin.compose'
13
13
 
14
14
  group = 'expo.modules.ui'
15
- version = '58.0.12'
15
+ version = '58.0.14'
16
16
 
17
17
  android {
18
18
  namespace "expo.modules.ui"
19
19
  defaultConfig {
20
20
  versionCode 1
21
- versionName "58.0.12"
21
+ versionName "58.0.14"
22
22
  testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
23
23
  }
24
24
  buildFeatures {
@@ -451,6 +451,7 @@ fun ExpoTimePickerDialogContent(props: TimePickerDialogProps, onDateSelected: (D
451
451
  Text(props.dismissButtonLabel ?: stringResource(android.R.string.cancel))
452
452
  }
453
453
  },
454
+ containerColor = timePickerColors.containerColor,
454
455
  text = {
455
456
  TimePicker(
456
457
  state = state,
@@ -1,5 +1,6 @@
1
1
  import './index.fx';
2
2
  export { useNativeState, type ObservableState } from './useNativeState';
3
3
  export { useWorkletProp } from './useWorkletProp';
4
+ export { useWorkletCallback, type WorkletCallback } from './useWorkletCallback';
4
5
  export { worklets } from './optionalWorklets';
5
6
  export { getStateId } from './utils';
@@ -5,6 +5,7 @@
5
5
  import './index.fx';
6
6
  export { useNativeState } from './useNativeState';
7
7
  export { useWorkletProp } from './useWorkletProp';
8
+ export { useWorkletCallback } from './useWorkletCallback';
8
9
  export { worklets } from './optionalWorklets';
9
10
  export { getStateId } from './utils';
10
11
 
@@ -1 +1 @@
1
- {"version":3,"sources":["State/index.ts"],"sourcesContent":[null],"names":["useNativeState","useWorkletProp","worklets","getStateId"],"mappings":"AAAA,oEAAoE;AACpE,oEAAoE;AACpE,oEAAoE;AACpE,mDAAmD;AACnD,OAAO,aAAa;AAEpB,SAASA,cAAc,QAA8B,mBAAmB;AACxE,SAASC,cAAc,QAAQ,mBAAmB;AAClD,SAASC,QAAQ,QAAQ,qBAAqB;AAC9C,SAASC,UAAU,QAAQ,UAAU"}
1
+ {"version":3,"sources":["State/index.ts"],"sourcesContent":[null],"names":["useNativeState","useWorkletProp","useWorkletCallback","worklets","getStateId"],"mappings":"AAAA,oEAAoE;AACpE,oEAAoE;AACpE,oEAAoE;AACpE,mDAAmD;AACnD,OAAO,aAAa;AAEpB,SAASA,cAAc,QAA8B,mBAAmB;AACxE,SAASC,cAAc,QAAQ,mBAAmB;AAClD,SAASC,kBAAkB,QAA8B,uBAAuB;AAChF,SAASC,QAAQ,QAAQ,qBAAqB;AAC9C,SAASC,UAAU,QAAQ,UAAU"}
@@ -0,0 +1,31 @@
1
+ import type { SharedObject } from 'expo';
2
+ /**
3
+ * A worklet function wrapped for native code, returned by [`useWorkletCallback`](#useworkletcallback).
4
+ * Pass it to a modifier or prop that accepts worklet callbacks, which then runs it synchronously on
5
+ * the UI thread.
6
+ */
7
+ export type WorkletCallback<T extends (...args: never[]) => void> = SharedObject & {
8
+ /** @hidden */
9
+ readonly __workletCallbackType?: T;
10
+ };
11
+ /**
12
+ * Wraps a worklet function so native code can run it synchronously on the UI thread, with no
13
+ * JS-thread round trip. Pass the result to a modifier that accepts worklet callbacks, such as
14
+ * `onHingeChange`. The callback must start with the `'worklet'` directive, and
15
+ * [`react-native-worklets`](https://docs.swmansion.com/react-native-worklets/) must be installed.
16
+ *
17
+ * The native callback is updated when `callback` changes and released when the component unmounts,
18
+ * so call it at the top of your component like any hook.
19
+ *
20
+ * @example
21
+ * ```tsx
22
+ * const angle = useNativeState(180);
23
+ * const onHinge = useWorkletCallback((_, newContext) => {
24
+ * 'worklet';
25
+ * angle.value = newContext.hinge?.angle ?? 180;
26
+ * });
27
+ *
28
+ * <VStack modifiers={[onHingeChange(onHinge)]} />
29
+ * ```
30
+ */
31
+ export declare function useWorkletCallback<T extends (...args: never[]) => void>(callback: T): WorkletCallback<T>;
@@ -0,0 +1,30 @@
1
+ import { worklets } from './optionalWorklets';
2
+ import { useWorkletProp } from './useWorkletProp';
3
+ /**
4
+ * Wraps a worklet function so native code can run it synchronously on the UI thread, with no
5
+ * JS-thread round trip. Pass the result to a modifier that accepts worklet callbacks, such as
6
+ * `onHingeChange`. The callback must start with the `'worklet'` directive, and
7
+ * [`react-native-worklets`](https://docs.swmansion.com/react-native-worklets/) must be installed.
8
+ *
9
+ * The native callback is updated when `callback` changes and released when the component unmounts,
10
+ * so call it at the top of your component like any hook.
11
+ *
12
+ * @example
13
+ * ```tsx
14
+ * const angle = useNativeState(180);
15
+ * const onHinge = useWorkletCallback((_, newContext) => {
16
+ * 'worklet';
17
+ * angle.value = newContext.hinge?.angle ?? 180;
18
+ * });
19
+ *
20
+ * <VStack modifiers={[onHingeChange(onHinge)]} />
21
+ * ```
22
+ */ export function useWorkletCallback(callback) {
23
+ const workletCallback = useWorkletProp(callback);
24
+ if (!worklets || !workletCallback) {
25
+ throw new Error("useWorkletCallback needs the 'react-native-worklets' package, which couldn't be loaded. " + 'Install react-native-worklets and rebuild the native app, or pass a plain function ' + 'where the API accepts one.');
26
+ }
27
+ return workletCallback;
28
+ }
29
+
30
+ //# sourceMappingURL=useWorkletCallback.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["State/useWorkletCallback.ts"],"sourcesContent":[null],"names":["worklets","useWorkletProp","useWorkletCallback","callback","workletCallback","Error"],"mappings":"AAEA,SAASA,QAAQ,QAAQ,qBAAqB;AAC9C,SAASC,cAAc,QAAQ,mBAAmB;AAYlD;;;;;;;;;;;;;;;;;;;CAmBC,GACD,OAAO,SAASC,mBACdC,QAAW;IAEX,MAAMC,kBAAkBH,eAAeE;IACvC,IAAI,CAACH,YAAY,CAACI,iBAAiB;QACjC,MAAM,IAAIC,MACR,6FACE,wFACA;IAEN;IACA,OAAOD;AACT"}
@@ -2,6 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { DateTimePicker as AndroidPicker, DatePickerDialog as AndroidDatePickerDialog, TimePickerDialog as AndroidTimePickerDialog } from '../../jetpack-compose/DatePicker';
3
3
  import { Host } from '../../jetpack-compose/Host';
4
4
  import { buildEvent, buildChangeEvent } from './types';
5
+ import { localDateToUtcDayISOString, utcDayToLocalDate } from './utils';
5
6
  function modeToDisplayedComponents(mode) {
6
7
  switch(mode){
7
8
  case 'time':
@@ -24,6 +25,13 @@ function displayToAndroidVariant(display) {
24
25
  }
25
26
  export function DateTimePicker(props) {
26
27
  const { value, onChange, onValueChange, onDismiss: onDismissProp, mode = 'date', minimumDate, maximumDate, display = 'default', is24Hour, testID, style, accentColor, presentation = 'dialog', positiveButton, negativeButton } = props;
28
+ // Material3 date pickers work in UTC days, while `value` and the reported date are local —
29
+ // matching `@react-native-community/datetimepicker`. Send `value`'s local calendar day as a UTC
30
+ // day and convert the picked UTC day back, keeping `value`'s time of day. The native side
31
+ // already converts `minimumDate`/`maximumDate` by their local calendar day. Time pickers read
32
+ // local hours from the instant, so they take `value` unchanged.
33
+ const usesDateComponents = mode !== 'time';
34
+ const initialDate = usesDateComponents ? localDateToUtcDayISOString(value) : value.toISOString();
27
35
  const onDismissed = ()=>{
28
36
  if (onDismissProp) {
29
37
  onDismissProp();
@@ -38,10 +46,11 @@ export function DateTimePicker(props) {
38
46
  }
39
47
  };
40
48
  const onDateSelected = (date)=>{
49
+ const selected = usesDateComponents ? utcDayToLocalDate(date, value) : date;
41
50
  if (onValueChange) {
42
- onValueChange(buildChangeEvent(date), date);
51
+ onValueChange(buildChangeEvent(selected), selected);
43
52
  } else {
44
- onChange?.(buildEvent(date), date);
53
+ onChange?.(buildEvent(selected), selected);
45
54
  }
46
55
  };
47
56
  const selectableDates = minimumDate || maximumDate ? {
@@ -49,7 +58,7 @@ export function DateTimePicker(props) {
49
58
  end: maximumDate
50
59
  } : undefined;
51
60
  const dialogProps = {
52
- initialDate: value.toISOString(),
61
+ initialDate,
53
62
  color: accentColor,
54
63
  confirmButtonLabel: positiveButton?.label,
55
64
  dismissButtonLabel: negativeButton?.label,
@@ -81,7 +90,7 @@ export function DateTimePicker(props) {
81
90
  },
82
91
  style: style,
83
92
  children: /*#__PURE__*/ _jsx(AndroidPicker, {
84
- initialDate: value.toISOString(),
93
+ initialDate: initialDate,
85
94
  displayedComponents: modeToDisplayedComponents(mode),
86
95
  variant: displayToAndroidVariant(display),
87
96
  selectableDates: selectableDates,
@@ -1 +1 @@
1
- {"version":3,"sources":["community/datetime-picker/DateTimePicker.android.tsx"],"sourcesContent":[null],"names":["DateTimePicker","AndroidPicker","DatePickerDialog","AndroidDatePickerDialog","TimePickerDialog","AndroidTimePickerDialog","Host","buildEvent","buildChangeEvent","modeToDisplayedComponents","mode","displayToAndroidVariant","display","props","value","onChange","onValueChange","onDismiss","onDismissProp","minimumDate","maximumDate","is24Hour","testID","style","accentColor","presentation","positiveButton","negativeButton","onDismissed","type","nativeEvent","timestamp","getTime","utcOffset","getTimezoneOffset","onDateSelected","date","selectableDates","start","end","undefined","dialogProps","initialDate","toISOString","color","confirmButtonLabel","label","dismissButtonLabel","onDismissRequest","variant","matchContents","vertical","displayedComponents","showVariantToggle"],"mappings":";AAAA,SACEA,kBAAkBC,aAAa,EAC/BC,oBAAoBC,uBAAuB,EAC3CC,oBAAoBC,uBAAuB,QAEtC,mCAAmC;AAC1C,SAASC,IAAI,QAAQ,6BAA6B;AAClD,SAASC,UAAU,EAAEC,gBAAgB,QAAkC,UAAU;AAEjF,SAASC,0BACPC,IAAiC;IAEjC,OAAQA;QACN,KAAK;YACH,OAAO;QACT,KAAK;YACH,kEAAkE;YAClE,OA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iBAAiBA;;;IAIzB;IAEA,qBACE,KAAC/B;QAAK4C,eAAe;YAAEC,UAAU;QAAK;QAAG5B,OAAOA;kBAC9C,cAAA,KAACtB;YACCyC,aAAa5B,MAAM6B,WAAW;YAC9BS,qBAAqB3C,0BAA0BC;YAC/CuC,SAAStC,wBAAwBC;YACjCyB,iBAAiBA;YACjBhB,UAAUA;YACVuB,OAAOpB;YACPW,gBAAgBA;YAChBkB,mBAAmB;YAClB,GAAI/B,SAAS;gBAAEA;YAAO,IAAIkB,SAAS;;;AAI5C"}
1
+ {"version":3,"sources":["community/datetime-picker/DateTimePicker.android.tsx"],"sourcesContent":[null],"names":["DateTimePicker","AndroidPicker","DatePickerDialog","AndroidDatePickerDialog","TimePickerDialog","AndroidTimePickerDialog","Host","buildEvent","buildChangeEvent","localDateToUtcDayISOString","utcDayToLocalDate","modeToDisplayedComponents","mode","displayToAndroidVariant","display","props","value","onChange","onValueChange","onDismiss","onDismissProp","minimumDate","maximumDate","is24Hour","testID","style","accentColor","presentation","positiveButton","negativeButton","usesDateComponents","initialDate","toISOString","onDismissed","type","nativeEvent","timestamp","getTime","utcOffset","getTimezoneOffset","onDateSelected","date","selected","selectableDates","start","end","undefined","dialogProps","color","confirmButtonLabel","label","dismissButtonLabel","onDismissRequest","variant","matchContents","vertical","displayedComponents","showVariantToggle"],"mappings":";AAAA,SACEA,kBAAkBC,aAAa,EAC/BC,oBAAoBC,uBAAuB,EAC3CC,oBAAoBC,uBAAuB,QAEtC,mCAAmC;AAC1C,SAASC,IAAI,QAAQ,6BAA6B;AAClD,SAASC,UAAU,EAAEC,gBAAgB,QAAkC,UAAU;AACjF,SAASC,0BAA0B,EAAEC,iBAAiB,QAAQ,UAAU;AAExE,SAASC,0BACPC,IAAiC;IAEjC,OAAQA;QACN,KAAK;YACH,OAAO;QACT,KAAK;YACH,kEAAkE;YAClE,OAAO;QACT,KAAK;QACL;YACE,OAAO;IACX;AACF;AAEA,SAASC,wBACPC,OAAuC;IAEvC,OA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ExB,UAAUA;;;QAG1D;QACA,qBACE,KAACjB;YAAKmB,OAAOA;sBACX,cAAA,KAACtB;gBACE,GAAG4C,WAAW;gBACfM,SAASxC,wBAAwBC;gBACjC6B,iBAAiBA;;;IAIzB;IAEA,qBACE,KAACrC;QAAKgD,eAAe;YAAEC,UAAU;QAAK;QAAG9B,OAAOA;kBAC9C,cAAA,KAACxB;YACC8B,aAAaA;YACbyB,qBAAqB7C,0BAA0BC;YAC/CyC,SAASxC,wBAAwBC;YACjC6B,iBAAiBA;YACjBpB,UAAUA;YACVyB,OAAOtB;YACPc,gBAAgBA;YAChBiB,mBAAmB;YAClB,GAAIjC,SAAS;gBAAEA;YAAO,IAAIsB,SAAS;;;AAI5C"}
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Returns the ISO string of the UTC midnight of `value`'s local calendar day, so Material3 shows
3
+ * the same day the user sees locally.
4
+ */
5
+ export declare function localDateToUtcDayISOString(value: Date): string;
6
+ /**
7
+ * Converts the UTC-midnight day reported by Material3 back into a local date, keeping the time of
8
+ * day from `timeOfDay`.
9
+ */
10
+ export declare function utcDayToLocalDate(utcDay: Date, timeOfDay: Date): Date;
@@ -0,0 +1,19 @@
1
+ // Material3's DatePicker (and the native side's `toUtcDayMillis` bounds conversion) works in UTC
2
+ // days, while `value`, `minimumDate`, and `maximumDate` are local dates — matching
3
+ // `@react-native-community/datetimepicker`. These helpers convert between the two.
4
+ /**
5
+ * Returns the ISO string of the UTC midnight of `value`'s local calendar day, so Material3 shows
6
+ * the same day the user sees locally.
7
+ */ export function localDateToUtcDayISOString(value) {
8
+ return new Date(Date.UTC(value.getFullYear(), value.getMonth(), value.getDate())).toISOString();
9
+ }
10
+ /**
11
+ * Converts the UTC-midnight day reported by Material3 back into a local date, keeping the time of
12
+ * day from `timeOfDay`.
13
+ */ export function utcDayToLocalDate(utcDay, timeOfDay) {
14
+ const result = new Date(timeOfDay);
15
+ result.setFullYear(utcDay.getUTCFullYear(), utcDay.getUTCMonth(), utcDay.getUTCDate());
16
+ return result;
17
+ }
18
+
19
+ //# sourceMappingURL=utils.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["community/datetime-picker/utils.ts"],"sourcesContent":[null],"names":["localDateToUtcDayISOString","value","Date","UTC","getFullYear","getMonth","getDate","toISOString","utcDayToLocalDate","utcDay","timeOfDay","result","setFullYear","getUTCFullYear","getUTCMonth","getUTCDate"],"mappings":"AAAA,iGAAiG;AACjG,mFAAmF;AACnF,mFAAmF;AAEnF;;;CAGC,GACD,OAAO,SAASA,2BAA2BC,KAAW;IACpD,OAAO,IAAIC,KAAKA,KAAKC,GAAG,CAACF,MAAMG,WAAW,IAAIH,MAAMI,QAAQ,IAAIJ,MAAMK,OAAO,KAAKC,WAAW;AAC/F;AAEA;;;CAGC,GACD,OAAO,SAASC,kBAAkBC,MAAY,EAAEC,SAAe;IAC7D,MAAMC,SAAS,IAAIT,KAAKQ;IACxBC,OAAOC,WAAW,CAACH,OAAOI,cAAc,IAAIJ,OAAOK,WAAW,IAAIL,OAAOM,UAAU;IACnF,OAAOJ;AACT"}
@@ -1 +1 @@
1
- {"version":3,"sources":["jetpack-compose/MaterialSymbolsAssetsTransformer.fx.ts"],"sourcesContent":[null],"names":["Image","resolveAssetSource","addCustomSourceTransformer","resolver","process","env","EXPO_OS","asset","type","serverUrl","assetServerURL","defaultAsset"],"mappings":"AAAA,SAASA,KAAK,QAAQ,eAAe;AAGrC,oEAAoE;AACpE,IAAI,OAAOA,MAAMC,kBAAkB,CAACC,0BAA0B,KAAK,YAAY;IAC7E,oEAAoE;IACpEF,MAAMC,kBAAkB,CAACC,0BAA0B,CAAC,CAACC;QACnD,IACEC,QAAQC,GAAG,CAACC,OAAO,KAAK,aACxBH,SAASI,KAAK,CAACC,IAAI,KAAK,SACxBL,SAASM,SAAS,IAAI,QACtBN,SAASM,SAAS,KAAK,IACvB;YACA,6FAA6F;YAC7F,kGAAkG;YAClG,oFAAoF;YACpF,8JAA8J;YAC9J,OAAON,SAASO,cAAc;QAChC;QACA,OAAOP,SAASQ,YAAY;IAC9B;AACF"}
1
+ {"version":3,"sources":["jetpack-compose/MaterialSymbolsAssetsTransformer.fx.ts"],"sourcesContent":[null],"names":["Image","resolveAssetSource","addCustomSourceTransformer","resolver","process","env","EXPO_OS","asset","type","serverUrl","assetServerURL","defaultAsset"],"mappings":"AAAA,SAASA,KAAK,QAAQ,eAAe;AAOrC,oEAAoE;AACpE,IAAI,OAAOA,MAAMC,kBAAkB,CAACC,0BAA0B,KAAK,YAAY;IAC7E,oEAAoE;IACpEF,MAAMC,kBAAkB,CAACC,0BAA0B,CAAC,CAACC;QACnD,IACEC,QAAQC,GAAG,CAACC,OAAO,KAAK,aACxBH,SAASI,KAAK,CAACC,IAAI,KAAK,SACxBL,SAASM,SAAS,IAAI,QACtBN,SAASM,SAAS,KAAK,IACvB;YACA,6FAA6F;YAC7F,kGAAkG;YAClG,oFAAoF;YACpF,8JAA8J;YAC9J,OAAON,SAASO,cAAc;QAChC;QACA,OAAOP,SAASQ,YAAY;IAC9B;AACF"}
@@ -49,6 +49,6 @@ export * from './Box';
49
49
  export * from './Row';
50
50
  export * from './Column';
51
51
  export * from './FlowRow';
52
- export { useNativeState } from '../State';
52
+ export { useNativeState, useWorkletCallback, type WorkletCallback } from '../State';
53
53
  export type { ViewEvent } from '../types';
54
54
  export type { PrimitiveBaseProps } from './layout-types';
@@ -49,6 +49,6 @@ export * from './Box';
49
49
  export * from './Row';
50
50
  export * from './Column';
51
51
  export * from './FlowRow';
52
- export { useNativeState } from '../State';
52
+ export { useNativeState, useWorkletCallback } from '../State';
53
53
 
54
54
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["jetpack-compose/index.ts"],"sourcesContent":[null],"names":["BasicAlertDialog","TextField","OutlinedTextField","BasicTextField","HorizontalPager","Text","useNativeState"],"mappings":"AAAA,OAAO,wCAAwC;AAE/C,cAAc,gBAAgB;AAC9B,cAAc,UAAU;AACxB,cAAc,cAAc;AAC5B,SAASA,gBAAgB,QAAoC,qBAAqB;AAClF,cAAc,SAAS;AACvB,cAAc,aAAa;AAC3B,cAAc,SAAS;AACvB,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,SAAS;AACvB,cAAc,UAAU;AACxB,cAAc,eAAe;AAC7B,cAAc,iBAAiB;AAC/B,cAAc,2BAA2B;AACzC,cAAc,YAAY;AAC1B,cAAc,SAAS;AACvB,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,aAAa;AAC3B,cAAc,eAAe;AAC7B,cAAc,eAAe;AAC7B,cAAc,oBAAoB;AAClC,cAAc,aAAa;AAC3B,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,eAAe;AAC7B,SACEC,SAAS,EACTC,iBAAiB,EACjBC,cAAc,QAcT,cAAc;AACrB,cAAc,iBAAiB;AAC/B,cAAc,UAAU;AACxB,cAAc,qBAAqB;AACnC,cAAc,kBAAkB;AAChC,cAAc,aAAa;AAC3B,SACEC,eAAe,QAGV,oBAAoB;AAC3B,cAAc,cAAc;AAC5B,cAAc,aAAa;AAC3B,cAAc,oBAAoB;AAClC,cAAc,8BAA8B;AAC5C,cAAc,yBAAyB;AACvC,cAAc,qBAAqB;AACnC,cAAc,gBAAgB;AAC9B,cAAc,YAAY;AAC1B,SAAyBC,IAAI,QAAQ,SAAS;AAC9C,cAAc,YAAY;AAC1B,cAAc,qBAAqB;AAEnC,cAAc,uBAAuB;AACrC,cAAc,QAAQ;AACtB,cAAc,QAAQ;AACtB,cAAc,WAAW;AACzB,cAAc,YAAY;AAC1B,SAASC,cAAc,QAAQ,WAAW"}
1
+ {"version":3,"sources":["jetpack-compose/index.ts"],"sourcesContent":[null],"names":["BasicAlertDialog","TextField","OutlinedTextField","BasicTextField","HorizontalPager","Text","useNativeState","useWorkletCallback"],"mappings":"AAAA,OAAO,wCAAwC;AAE/C,cAAc,gBAAgB;AAC9B,cAAc,UAAU;AACxB,cAAc,cAAc;AAC5B,SAASA,gBAAgB,QAAoC,qBAAqB;AAClF,cAAc,SAAS;AACvB,cAAc,aAAa;AAC3B,cAAc,SAAS;AACvB,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,SAAS;AACvB,cAAc,UAAU;AACxB,cAAc,eAAe;AAC7B,cAAc,iBAAiB;AAC/B,cAAc,2BAA2B;AACzC,cAAc,YAAY;AAC1B,cAAc,SAAS;AACvB,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,aAAa;AAC3B,cAAc,eAAe;AAC7B,cAAc,eAAe;AAC7B,cAAc,oBAAoB;AAClC,cAAc,aAAa;AAC3B,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,eAAe;AAC7B,SACEC,SAAS,EACTC,iBAAiB,EACjBC,cAAc,QAcT,cAAc;AACrB,cAAc,iBAAiB;AAC/B,cAAc,UAAU;AACxB,cAAc,qBAAqB;AACnC,cAAc,kBAAkB;AAChC,cAAc,aAAa;AAC3B,SACEC,eAAe,QAGV,oBAAoB;AAC3B,cAAc,cAAc;AAC5B,cAAc,aAAa;AAC3B,cAAc,oBAAoB;AAClC,cAAc,8BAA8B;AAC5C,cAAc,yBAAyB;AACvC,cAAc,qBAAqB;AACnC,cAAc,gBAAgB;AAC9B,cAAc,YAAY;AAC1B,SAAyBC,IAAI,QAAQ,SAAS;AAC9C,cAAc,YAAY;AAC1B,cAAc,qBAAqB;AAEnC,cAAc,uBAAuB;AACrC,cAAc,QAAQ;AACtB,cAAc,QAAQ;AACtB,cAAc,WAAW;AACzB,cAAc,YAAY;AAC1B,SAASC,cAAc,EAAEC,kBAAkB,QAA8B,WAAW"}
@@ -0,0 +1,48 @@
1
+ import { type CommonViewModifierProps } from '../types';
2
+ export interface ArrangementViewProps extends CommonViewModifierProps {
3
+ /**
4
+ * The views to arrange. Provide `ArrangementView.Primary` and `ArrangementView.Secondary`.
5
+ */
6
+ children: React.ReactNode;
7
+ }
8
+ /**
9
+ * The primary view of the arrangement.
10
+ */
11
+ declare function ArrangementViewPrimary(props: {
12
+ children: React.ReactNode;
13
+ }): import("react").JSX.Element;
14
+ /**
15
+ * The secondary view of the arrangement.
16
+ */
17
+ declare function ArrangementViewSecondary(props: {
18
+ children: React.ReactNode;
19
+ }): import("react").JSX.Element;
20
+ /**
21
+ * ArrangementView uses the native [ArrangementView](https://developer.apple.com/documentation/swiftui/arrangementview) view.
22
+ *
23
+ * A view that arranges primary and secondary content using an adaptive layout that responds to
24
+ * the environment.
25
+ *
26
+ * > **Note:** Below iOS 27.1, the children render without a container.
27
+ * @example
28
+ * ```tsx
29
+ * <Host style={{ flex: 1 }}>
30
+ * <ArrangementView modifiers={[arrangementViewStyle('split')]}>
31
+ * <ArrangementView.Primary>
32
+ * <NowPlaying />
33
+ * </ArrangementView.Primary>
34
+ * <ArrangementView.Secondary>
35
+ * <Lyrics />
36
+ * </ArrangementView.Secondary>
37
+ * </ArrangementView>
38
+ * </Host>
39
+ * ```
40
+ * @platform ios 27.1+
41
+ * @platform tvos 27.1+
42
+ */
43
+ export declare function ArrangementView(props: ArrangementViewProps): import("react").JSX.Element;
44
+ export declare namespace ArrangementView {
45
+ var Primary: typeof ArrangementViewPrimary;
46
+ var Secondary: typeof ArrangementViewSecondary;
47
+ }
48
+ export {};
@@ -0,0 +1,56 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { requireNativeView } from 'expo';
3
+ import { Slot } from '../SlotView';
4
+ import { createViewModifierEventListener } from '../modifiers/utils';
5
+ const ArrangementViewNativeView = requireNativeView('ExpoUI', 'ArrangementViewView');
6
+ /**
7
+ * The primary view of the arrangement.
8
+ */ function ArrangementViewPrimary(props) {
9
+ return /*#__PURE__*/ _jsx(Slot, {
10
+ name: "primary",
11
+ children: props.children
12
+ });
13
+ }
14
+ /**
15
+ * The secondary view of the arrangement.
16
+ */ function ArrangementViewSecondary(props) {
17
+ return /*#__PURE__*/ _jsx(Slot, {
18
+ name: "secondary",
19
+ children: props.children
20
+ });
21
+ }
22
+ ArrangementView.Primary = ArrangementViewPrimary;
23
+ ArrangementView.Secondary = ArrangementViewSecondary;
24
+ /**
25
+ * ArrangementView uses the native [ArrangementView](https://developer.apple.com/documentation/swiftui/arrangementview) view.
26
+ *
27
+ * A view that arranges primary and secondary content using an adaptive layout that responds to
28
+ * the environment.
29
+ *
30
+ * > **Note:** Below iOS 27.1, the children render without a container.
31
+ * @example
32
+ * ```tsx
33
+ * <Host style={{ flex: 1 }}>
34
+ * <ArrangementView modifiers={[arrangementViewStyle('split')]}>
35
+ * <ArrangementView.Primary>
36
+ * <NowPlaying />
37
+ * </ArrangementView.Primary>
38
+ * <ArrangementView.Secondary>
39
+ * <Lyrics />
40
+ * </ArrangementView.Secondary>
41
+ * </ArrangementView>
42
+ * </Host>
43
+ * ```
44
+ * @platform ios 27.1+
45
+ * @platform tvos 27.1+
46
+ */ export function ArrangementView(props) {
47
+ const { modifiers, children, ...restProps } = props;
48
+ return /*#__PURE__*/ _jsx(ArrangementViewNativeView, {
49
+ modifiers: modifiers,
50
+ ...modifiers ? createViewModifierEventListener(modifiers) : undefined,
51
+ ...restProps,
52
+ children: children
53
+ });
54
+ }
55
+
56
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["swift-ui/ArrangementView/index.tsx"],"sourcesContent":[null],"names":["requireNativeView","Slot","createViewModifierEventListener","ArrangementViewNativeView","ArrangementViewPrimary","props","name","children","ArrangementViewSecondary","ArrangementView","Primary","Secondary","modifiers","restProps","undefined"],"mappings":";AAAA,SAASA,iBAAiB,QAAQ,OAAO;AAEzC,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,+BAA+B,QAAQ,qBAAqB;AAUrE,MAAMC,4BAAuEH,kBAC3E,UACA;AAGF;;CAEC,GACD,SAASI,uBAAuBC,KAAoC;IAClE,qBAAO,KAACJ;QAAKK,MAAK;kBAAWD,MAAME,QAAQ;;AAC7C;AAEA;;CAEC,GACD,SAASC,yBAAyBH,KAAoC;IACpE,qBAAO,KAACJ;QAAKK,MAAK;kBAAaD,MAAME,QAAQ;;AAC/C;AAEAE,gBAAgBC,OAAO,GAAGN;AAC1BK,gBAAgBE,SAAS,GAAGH;AAE5B;;;;;;;;;;;;;;;;;;;;;;CAsBC,GACD,OAAO,SAASC,gBAAgBJ,KAA2B;IACzD,MAAM,EAAEO,SAAS,EAAEL,QAAQ,EAAE,GAAGM,WAAW,GAAGR;IAE9C,qBACE,KAACF;QACCS,WAAWA;QACV,GAAIA,YAAYV,gCAAgCU,aAAaE,SAAS;QACtE,GAAGD,SAAS;kBACZN;;AAGP"}
@@ -29,6 +29,7 @@ export * from './Menu';
29
29
  export * from './NavigationDestination';
30
30
  export * from './NavigationLink';
31
31
  export * from './NavigationSplitView';
32
+ export * from './ArrangementView';
32
33
  export * from './NavigationStack';
33
34
  export * from './Picker';
34
35
  export * from './ProgressView';
@@ -39,7 +40,7 @@ export * from './Spacer';
39
40
  export * from './Stepper';
40
41
  export * from './SwipeActions';
41
42
  export * from './Text';
42
- export { useNativeState } from '../State';
43
+ export { useNativeState, useWorkletCallback, type WorkletCallback } from '../State';
43
44
  export { withAnimation, type WithAnimationCompletionCriteria } from './withAnimation';
44
45
  export * from './SyncToggle';
45
46
  export * from './TabView';
@@ -28,6 +28,7 @@ export * from './Menu';
28
28
  export * from './NavigationDestination';
29
29
  export * from './NavigationLink';
30
30
  export * from './NavigationSplitView';
31
+ export * from './ArrangementView';
31
32
  export * from './NavigationStack';
32
33
  export * from './Picker';
33
34
  export * from './ProgressView';
@@ -38,7 +39,7 @@ export * from './Spacer';
38
39
  export * from './Stepper';
39
40
  export * from './SwipeActions';
40
41
  export * from './Text';
41
- export { useNativeState } from '../State';
42
+ export { useNativeState, useWorkletCallback } from '../State';
42
43
  export { withAnimation } from './withAnimation';
43
44
  export * from './SyncToggle';
44
45
  export * from './TabView';
@@ -1 +1 @@
1
- {"version":3,"sources":["swift-ui/index.tsx"],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"version":3,"sources":["swift-ui/index.tsx"],"sourcesContent":[null],"names":["useNativeState","useWorkletCallback","withAnimation","TextField"],"mappings":"AAAA,cAAc,8BAA8B;AAC5C,cAAc,UAAU;AACxB,cAAc,gBAAgB;AAC9B,cAAc,WAAW;AACzB,cAAc,UAAU;AACxB,cAAc,gBAAgB;AAC9B,cAAc,2BAA2B;AACzC,cAAc,uBAAuB;AACrC,cAAc,iBAAiB;AAC/B,cAAc,gBAAgB;AAC9B,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,oBAAoB;AAClC,cAAc,SAAS;AACvB,cAAc,UAAU;AACxB,cAAc,SAAS;AACvB,cAAc,UAAU;AACxB,cAAc,UAAU;AACxB,cAAc,mBAAmB;AACjC,cAAc,WAAW;AACzB,cAAc,eAAe;AAC7B,cAAc,eAAe;AAE7B,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,UAAU;AACxB,cAAc,SAAS;AACvB,cAAc,SAAS;AACvB,cAAc,0BAA0B;AACxC,cAAc,mBAAmB;AACjC,cAAc,wBAAwB;AACtC,cAAc,oBAAoB;AAClC,cAAc,oBAAoB;AAClC,cAAc,WAAW;AACzB,cAAc,iBAAiB;AAC/B,cAAc,YAAY;AAC1B,cAAc,cAAc;AAC5B,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,YAAY;AAC1B,cAAc,iBAAiB;AAC/B,cAAc,SAAS;AACvB,SAASA,cAAc,EAAEC,kBAAkB,QAA8B,WAAW;AACpF,SAASC,aAAa,QAA8C,kBAAkB;AACtF,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,YAAY;AAC1B,cAAc,WAAW;AACzB,SACEC,SAAS,QAIJ,cAAc;AACrB,cAAc,gBAAgB;AAC9B,cAAc,cAAc;AAC5B,cAAc,yBAAyB;AACvC,cAAc,eAAe;AAC7B,cAAc,WAAW;AACzB,cAAc,SAAS;AACvB,cAAc,YAAY;AAC1B,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,SAAS;AACvB,cAAc,eAAe;AAC7B,cAAc,SAAS"}
@@ -0,0 +1,109 @@
1
+ import { createModifier } from './createModifier';
2
+ /**
3
+ * A style that configures an `ArrangementView` with an arrangement.
4
+ * - `'automatic'`: The default style, which resolves to `'split'`.
5
+ * - `'split'`: An arrangement view style that places the primary and secondary views side by side along one or more axes.
6
+ * - `'overlay'`: An arrangement view style that layers the primary view over the secondary view in z-order.
7
+ */
8
+ export type ArrangementViewStyle = 'automatic' | 'split' | 'overlay';
9
+ /**
10
+ * Sets the style for arrangement views within this view.
11
+ * @param style - The style to apply.
12
+ * @param options - The `axes` the arrangement supports. With `'split'`, creates a split arrangement
13
+ * that supports the given axes. With `'overlay'`, creates an overlay arrangement that supports
14
+ * laying out its views along the given axes.
15
+ * @platform ios 27.1+
16
+ * @platform tvos 27.1+
17
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/arrangementviewstyle(_:)).
18
+ */
19
+ export declare function arrangementViewStyle(style: 'automatic'): ReturnType<typeof createModifier>;
20
+ export declare function arrangementViewStyle(style: 'split' | 'overlay', options?: {
21
+ axes?: 'horizontal' | 'vertical' | 'both';
22
+ }): ReturnType<typeof createModifier>;
23
+ /**
24
+ * The minimum, ideal, and maximum ratios for `splitArrangementLayoutRatio`.
25
+ */
26
+ export type SplitArrangementLayoutRatioParams = {
27
+ minHorizontal?: number;
28
+ idealHorizontal?: number;
29
+ maxHorizontal?: number;
30
+ minVertical?: number;
31
+ idealVertical?: number;
32
+ maxVertical?: number;
33
+ };
34
+ /**
35
+ * Sets the preferred size ratio for the content of `ArrangementView.Primary` or
36
+ * `ArrangementView.Secondary` in a split arrangement.
37
+ * @platform ios 27.1+
38
+ * @platform tvos 27.1+
39
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/splitarrangementlayoutratio(_:)).
40
+ */
41
+ export declare function splitArrangementLayoutRatio(ratio: number): ReturnType<typeof createModifier>;
42
+ /**
43
+ * Sets the size ratio for the content of `ArrangementView.Primary` or `ArrangementView.Secondary`
44
+ * in a split arrangement.
45
+ * @platform ios 27.1+
46
+ * @platform tvos 27.1+
47
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/splitarrangementlayoutratio(minhorizontal:idealhorizontal:maxhorizontal:minvertical:idealvertical:maxvertical:)).
48
+ */
49
+ export declare function splitArrangementLayoutRatio(ratios: SplitArrangementLayoutRatioParams): ReturnType<typeof createModifier>;
50
+ /**
51
+ * The minimum, ideal, and maximum sizes for `splitArrangementLayoutSize`.
52
+ */
53
+ export type SplitArrangementLayoutSizeParams = {
54
+ minWidth?: number;
55
+ idealWidth?: number;
56
+ maxWidth?: number;
57
+ minHeight?: number;
58
+ idealHeight?: number;
59
+ maxHeight?: number;
60
+ };
61
+ /**
62
+ * Sets the size constraints for the content of `ArrangementView.Primary` or
63
+ * `ArrangementView.Secondary` in a split arrangement.
64
+ * @platform ios 27.1+
65
+ * @platform tvos 27.1+
66
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/splitarrangementlayoutsize(minwidth:idealwidth:maxwidth:minheight:idealheight:maxheight:)).
67
+ */
68
+ export declare const splitArrangementLayoutSize: (constraints: SplitArrangementLayoutSizeParams) => import("./createModifier").ModifierConfig;
69
+ /**
70
+ * The split axes on which `splitArrangementFixedLayoutSize` prefers the ideal size of the view.
71
+ */
72
+ export type SplitArrangementFixedLayoutSizeParams = {
73
+ /**
74
+ * Whether to prefer a fixed width for the view in a horizontal split.
75
+ * @default true
76
+ */
77
+ horizontal?: boolean;
78
+ /**
79
+ * Whether to prefer a fixed height for the view in a vertical split.
80
+ * @default true
81
+ */
82
+ vertical?: boolean;
83
+ };
84
+ /**
85
+ * Sets the preferred size constraint for the content of `ArrangementView.Primary` or
86
+ * `ArrangementView.Secondary` in a split arrangement to the ideal size of the view within its
87
+ * container. The arrangement view prefers this size, but may resize to a smaller size depending on
88
+ * the priority of the view.
89
+ * @platform ios 27.1+
90
+ * @platform tvos 27.1+
91
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/splitarrangementfixedlayoutsize(horizontal:vertical:)).
92
+ */
93
+ export declare const splitArrangementFixedLayoutSize: (options?: SplitArrangementFixedLayoutSizeParams) => import("./createModifier").ModifierConfig;
94
+ /**
95
+ * Sets the horizontal edge that a view in an overlay arrangement occupies when the arrangement
96
+ * transitions to a horizontal layout.
97
+ * @platform ios 27.1+
98
+ * @platform tvos 27.1+
99
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/overlayarrangementedge(_:)).
100
+ */
101
+ export declare function overlayArrangementEdge(edge: 'leading' | 'trailing'): ReturnType<typeof createModifier>;
102
+ /**
103
+ * Sets the vertical edge that a view in an overlay arrangement occupies when the arrangement
104
+ * transitions to a vertical layout.
105
+ * @platform ios 27.1+
106
+ * @platform tvos 27.1+
107
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/overlayarrangementedge(_:)-4tjwn).
108
+ */
109
+ export declare function overlayArrangementEdge(edge: 'top' | 'bottom'): ReturnType<typeof createModifier>;
@@ -0,0 +1,35 @@
1
+ import { createModifier } from './createModifier';
2
+ export function arrangementViewStyle(style, options) {
3
+ return createModifier('arrangementViewStyle', {
4
+ style,
5
+ axes: options?.axes
6
+ });
7
+ }
8
+ export function splitArrangementLayoutRatio(ratioOrParams) {
9
+ return createModifier('splitArrangementLayoutRatio', typeof ratioOrParams === 'number' ? {
10
+ ratio: ratioOrParams
11
+ } : ratioOrParams);
12
+ }
13
+ /**
14
+ * Sets the size constraints for the content of `ArrangementView.Primary` or
15
+ * `ArrangementView.Secondary` in a split arrangement.
16
+ * @platform ios 27.1+
17
+ * @platform tvos 27.1+
18
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/splitarrangementlayoutsize(minwidth:idealwidth:maxwidth:minheight:idealheight:maxheight:)).
19
+ */ export const splitArrangementLayoutSize = (constraints)=>createModifier('splitArrangementLayoutSize', constraints);
20
+ /**
21
+ * Sets the preferred size constraint for the content of `ArrangementView.Primary` or
22
+ * `ArrangementView.Secondary` in a split arrangement to the ideal size of the view within its
23
+ * container. The arrangement view prefers this size, but may resize to a smaller size depending on
24
+ * the priority of the view.
25
+ * @platform ios 27.1+
26
+ * @platform tvos 27.1+
27
+ * @see Official [SwiftUI documentation](https://developer.apple.com/documentation/swiftui/view/splitarrangementfixedlayoutsize(horizontal:vertical:)).
28
+ */ export const splitArrangementFixedLayoutSize = (options)=>createModifier('splitArrangementFixedLayoutSize', options);
29
+ export function overlayArrangementEdge(edge) {
30
+ return createModifier('overlayArrangementEdge', {
31
+ edge
32
+ });
33
+ }
34
+
35
+ //# sourceMappingURL=arrangementModifiers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["swift-ui/modifiers/arrangementModifiers.ts"],"sourcesContent":[null],"names":["createModifier","arrangementViewStyle","style","options","axes","splitArrangementLayoutRatio","ratioOrParams","ratio","splitArrangementLayoutSize","constraints","splitArrangementFixedLayoutSize","overlayArrangementEdge","edge"],"mappings":"AAAA,SAASA,cAAc,QAAQ,mBAAmB;AAyBlD,OAAO,SAASC,qBACdC,KAA2B,EAC3BC,OAAuD;IAEvD,OAAOH,eAAe,wBAAwB;QAAEE;QAAOE,MAAMD,SAASC;IAAK;AAC7E;AAgCA,OAAO,SAASC,4BACdC,aAAyD;IAEzD,OAAON,eACL,+BACA,OAAOM,kBAAkB,WAAW;QAAEC,OAAOD;IAAc,IAAIA;AAEnE;AAcA;;;;;;CAMC,GACD,OAAO,MAAME,6BAA6B,CAACC,cACzCT,eAAe,8BAA8BS,aAAa;AAkB5D;;;;;;;;CAQC,GACD,OAAO,MAAMC,kCAAkC,CAACP,UAC9CH,eAAe,mCAAmCG,SAAS;AAoB7D,OAAO,SAASQ,uBAAuBC,IAA+C;IACpF,OAAOZ,eAAe,0BAA0B;QAAEY;IAAK;AACzD"}