@gaozh1024/rn-kit 0.3.0 → 0.3.2

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/dist/index.js CHANGED
@@ -33,12 +33,14 @@ __export(index_exports, {
33
33
  ActionIcons: () => ActionIcons,
34
34
  Alert: () => Alert,
35
35
  AppButton: () => AppButton,
36
+ AppFocusedStatusBar: () => AppFocusedStatusBar,
36
37
  AppHeader: () => AppHeader,
37
38
  AppImage: () => AppImage,
38
39
  AppInput: () => AppInput,
39
40
  AppList: () => AppList,
40
41
  AppPressable: () => AppPressable,
41
42
  AppProvider: () => AppProvider,
43
+ AppScreen: () => AppScreen,
42
44
  AppScrollView: () => AppScrollView,
43
45
  AppStatusBar: () => AppStatusBar,
44
46
  AppText: () => AppText,
@@ -63,7 +65,6 @@ __export(index_exports, {
63
65
  NavigationIcons: () => NavigationIcons,
64
66
  NavigationProvider: () => NavigationProvider,
65
67
  OverlayProvider: () => OverlayProvider,
66
- Page: () => Page,
67
68
  PageDrawer: () => PageDrawer,
68
69
  Progress: () => Progress,
69
70
  Radio: () => Radio,
@@ -1397,7 +1398,7 @@ var styles = import_react_native5.StyleSheet.create({
1397
1398
  flex: 1
1398
1399
  }
1399
1400
  });
1400
- function Page({
1401
+ function AppScreen({
1401
1402
  children,
1402
1403
  className,
1403
1404
  ...props
@@ -1723,7 +1724,8 @@ function Card({
1723
1724
  }
1724
1725
 
1725
1726
  // src/ui/display/Icon.tsx
1726
- var import_MaterialIcons = __toESM(require("react-native-vector-icons/MaterialIcons"));
1727
+ var import_react_native10 = require("react-native");
1728
+ var import_vector_icons = require("@expo/vector-icons");
1727
1729
  var import_jsx_runtime16 = require("nativewind/jsx-runtime");
1728
1730
  var sizeMap2 = {
1729
1731
  xs: 16,
@@ -1732,6 +1734,12 @@ var sizeMap2 = {
1732
1734
  lg: 32,
1733
1735
  xl: 48
1734
1736
  };
1737
+ function isComponentLike(value) {
1738
+ if (typeof value === "function") return true;
1739
+ if (typeof value !== "object" || value === null) return false;
1740
+ return "$$typeof" in value;
1741
+ }
1742
+ var MaterialIconComponent = isComponentLike(import_vector_icons.MaterialIcons) ? import_vector_icons.MaterialIcons : void 0;
1735
1743
  function resolveSize(size = "md") {
1736
1744
  if (typeof size === "number") return size;
1737
1745
  return sizeMap2[size] || 24;
@@ -1740,11 +1748,37 @@ function Icon({ name, size = "md", color = "gray-600", style, onPress, testID })
1740
1748
  const { theme, isDark } = useOptionalTheme();
1741
1749
  const resolvedSize = resolveSize(size);
1742
1750
  const resolvedColor = resolveNamedColor(color, theme, isDark) ?? color;
1751
+ const fallback = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1752
+ import_react_native10.Text,
1753
+ {
1754
+ style: [
1755
+ {
1756
+ color: resolvedColor,
1757
+ fontSize: resolvedSize,
1758
+ lineHeight: resolvedSize
1759
+ },
1760
+ style
1761
+ ],
1762
+ testID,
1763
+ children: "\u25A1"
1764
+ }
1765
+ );
1766
+ if (!MaterialIconComponent) {
1767
+ return onPress ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(AppPressable, { onPress, children: fallback }) : fallback;
1768
+ }
1743
1769
  if (onPress) {
1744
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(AppPressable, { onPress, testID, children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_MaterialIcons.default, { name, size: resolvedSize, color: resolvedColor, style }) });
1770
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(AppPressable, { onPress, testID, children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1771
+ MaterialIconComponent,
1772
+ {
1773
+ name,
1774
+ size: resolvedSize,
1775
+ color: resolvedColor,
1776
+ style
1777
+ }
1778
+ ) });
1745
1779
  }
1746
1780
  return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1747
- import_MaterialIcons.default,
1781
+ MaterialIconComponent,
1748
1782
  {
1749
1783
  name,
1750
1784
  size: resolvedSize,
@@ -1800,7 +1834,7 @@ var FileIcons = {
1800
1834
 
1801
1835
  // src/ui/display/AppImage.tsx
1802
1836
  var import_react14 = require("react");
1803
- var import_react_native10 = require("react-native");
1837
+ var import_react_native11 = require("react-native");
1804
1838
  var import_jsx_runtime17 = require("nativewind/jsx-runtime");
1805
1839
  var radiusMap = {
1806
1840
  none: 0,
@@ -1863,7 +1897,7 @@ function AppImage({
1863
1897
  if (!isLoading) return null;
1864
1898
  if (placeholder) {
1865
1899
  return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
1866
- import_react_native10.Image,
1900
+ import_react_native11.Image,
1867
1901
  {
1868
1902
  source: placeholder,
1869
1903
  style: {
@@ -1884,7 +1918,7 @@ function AppImage({
1884
1918
  center: true,
1885
1919
  className: "absolute inset-0 bg-gray-100",
1886
1920
  style: { borderRadius: resolvedRadius },
1887
- children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_react_native10.ActivityIndicator, { color: theme.colors.primary?.[500] })
1921
+ children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_react_native11.ActivityIndicator, { color: theme.colors.primary?.[500] })
1888
1922
  }
1889
1923
  );
1890
1924
  }
@@ -1896,7 +1930,7 @@ function AppImage({
1896
1930
  if (!hasError) return null;
1897
1931
  if (errorPlaceholder) {
1898
1932
  return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
1899
- import_react_native10.Image,
1933
+ import_react_native11.Image,
1900
1934
  {
1901
1935
  source: errorPlaceholder,
1902
1936
  style: {
@@ -1925,7 +1959,7 @@ function AppImage({
1925
1959
  const isNumberWidth = typeof width === "number";
1926
1960
  const isNumberHeight = typeof height === "number";
1927
1961
  const content = /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
1928
- import_react_native10.View,
1962
+ import_react_native11.View,
1929
1963
  {
1930
1964
  className: cn("overflow-hidden", className),
1931
1965
  style: {
@@ -1937,7 +1971,7 @@ function AppImage({
1937
1971
  children: [
1938
1972
  renderLoading(),
1939
1973
  /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
1940
- import_react_native10.Image,
1974
+ import_react_native11.Image,
1941
1975
  {
1942
1976
  source,
1943
1977
  style: imageStyle,
@@ -1958,7 +1992,7 @@ function AppImage({
1958
1992
 
1959
1993
  // src/ui/display/AppList.tsx
1960
1994
  var import_react15 = require("react");
1961
- var import_react_native11 = require("react-native");
1995
+ var import_react_native12 = require("react-native");
1962
1996
  var import_jsx_runtime18 = require("nativewind/jsx-runtime");
1963
1997
  function SkeletonItem2({ render }) {
1964
1998
  const colors = useThemeColors();
@@ -1985,12 +2019,18 @@ function EmptyState({
1985
2019
  description && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(AppText, { size: "sm", className: "mt-2", style: { color: colors.textMuted }, children: description })
1986
2020
  ] });
1987
2021
  }
1988
- function ErrorState({ error, onRetry }) {
2022
+ function ErrorState({
2023
+ error,
2024
+ onRetry,
2025
+ errorTitle,
2026
+ errorDescription,
2027
+ retryText
2028
+ }) {
1989
2029
  const colors = useThemeColors();
1990
2030
  return /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(Center, { py: 20, children: [
1991
2031
  /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(Icon, { name: "error-outline", size: 64, color: "error-300" }),
1992
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(AppText, { size: "lg", weight: "medium", color: "error-500", className: "mt-4", children: "\u52A0\u8F7D\u5931\u8D25" }),
1993
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(AppText, { size: "sm", style: { color: colors.textMuted }, className: "mt-2 text-center px-8", children: error.message || "\u8BF7\u68C0\u67E5\u7F51\u7EDC\u540E\u91CD\u8BD5" }),
2032
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(AppText, { size: "lg", weight: "medium", color: "error-500", className: "mt-4", children: errorTitle || "\u52A0\u8F7D\u5931\u8D25" }),
2033
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(AppText, { size: "sm", style: { color: colors.textMuted }, className: "mt-2 text-center px-8", children: error.message || errorDescription || "\u8BF7\u68C0\u67E5\u7F51\u7EDC\u540E\u91CD\u8BD5" }),
1994
2034
  onRetry && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
1995
2035
  AppPressable,
1996
2036
  {
@@ -2000,14 +2040,14 @@ function ErrorState({ error, onRetry }) {
2000
2040
  styles3.retryButton,
2001
2041
  { backgroundColor: colors.cardElevated, borderColor: colors.border }
2002
2042
  ],
2003
- children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(AppText, { style: { color: colors.textSecondary }, className: "text-center", children: "\u91CD\u65B0\u52A0\u8F7D" })
2043
+ children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(AppText, { style: { color: colors.textSecondary }, className: "text-center", children: retryText || "\u91CD\u65B0\u52A0\u8F7D" })
2004
2044
  }
2005
2045
  )
2006
2046
  ] });
2007
2047
  }
2008
2048
  function LoadMoreFooter({ loading }) {
2009
2049
  if (!loading) return null;
2010
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(Center, { py: 4, children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react_native11.ActivityIndicator, { size: "small" }) });
2050
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(Center, { py: 4, children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react_native12.ActivityIndicator, { size: "small" }) });
2011
2051
  }
2012
2052
  function Divider({ style }) {
2013
2053
  const colors = useThemeColors();
@@ -2031,6 +2071,9 @@ function AppList({
2031
2071
  onEndReachedThreshold = 0.5,
2032
2072
  error,
2033
2073
  onRetry,
2074
+ errorTitle,
2075
+ errorDescription,
2076
+ retryText,
2034
2077
  emptyTitle,
2035
2078
  emptyDescription,
2036
2079
  emptyIcon,
@@ -2086,7 +2129,7 @@ function AppList({
2086
2129
  );
2087
2130
  if (loading && data.length === 0) {
2088
2131
  return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2089
- import_react_native11.FlatList,
2132
+ import_react_native12.FlatList,
2090
2133
  {
2091
2134
  data: skeletonData,
2092
2135
  renderItem: skeletonRenderItem,
@@ -2099,7 +2142,16 @@ function AppList({
2099
2142
  );
2100
2143
  }
2101
2144
  if (error && data.length === 0) {
2102
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(Center, { style, children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(ErrorState, { error, onRetry }) });
2145
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(Center, { style, children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2146
+ ErrorState,
2147
+ {
2148
+ error,
2149
+ onRetry,
2150
+ errorTitle,
2151
+ errorDescription,
2152
+ retryText
2153
+ }
2154
+ ) });
2103
2155
  }
2104
2156
  const ListEmptyComponent = (0, import_react15.useMemo)(() => {
2105
2157
  if (EmptyComponent) return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(EmptyComponent, {});
@@ -2112,13 +2164,13 @@ function AppList({
2112
2164
  ] });
2113
2165
  }, [isLoadingMore, ListFooterComponent]);
2114
2166
  return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2115
- import_react_native11.FlatList,
2167
+ import_react_native12.FlatList,
2116
2168
  {
2117
2169
  data,
2118
2170
  renderItem: wrappedRenderItem,
2119
2171
  keyExtractor: defaultKeyExtractor,
2120
2172
  refreshControl: onRefresh ? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2121
- import_react_native11.RefreshControl,
2173
+ import_react_native12.RefreshControl,
2122
2174
  {
2123
2175
  refreshing,
2124
2176
  onRefresh,
@@ -2145,7 +2197,7 @@ function AppList({
2145
2197
  }
2146
2198
  );
2147
2199
  }
2148
- var styles3 = import_react_native11.StyleSheet.create({
2200
+ var styles3 = import_react_native12.StyleSheet.create({
2149
2201
  retryButton: {
2150
2202
  borderWidth: 0.5
2151
2203
  }
@@ -2153,7 +2205,7 @@ var styles3 = import_react_native11.StyleSheet.create({
2153
2205
 
2154
2206
  // src/ui/display/PageDrawer.tsx
2155
2207
  var import_react16 = __toESM(require("react"));
2156
- var import_react_native12 = require("react-native");
2208
+ var import_react_native13 = require("react-native");
2157
2209
  var import_jsx_runtime19 = require("nativewind/jsx-runtime");
2158
2210
  function PageDrawer({
2159
2211
  visible,
@@ -2181,14 +2233,14 @@ function PageDrawer({
2181
2233
  }, [onClose]);
2182
2234
  import_react16.default.useEffect(() => {
2183
2235
  if (!visible) return;
2184
- const subscription = import_react_native12.BackHandler.addEventListener("hardwareBackPress", () => {
2236
+ const subscription = import_react_native13.BackHandler.addEventListener("hardwareBackPress", () => {
2185
2237
  handleClose();
2186
2238
  return true;
2187
2239
  });
2188
2240
  return () => subscription.remove();
2189
2241
  }, [handleClose, visible]);
2190
2242
  const panResponder = import_react16.default.useMemo(
2191
- () => import_react_native12.PanResponder.create({
2243
+ () => import_react_native13.PanResponder.create({
2192
2244
  onMoveShouldSetPanResponder: (_event, gestureState) => {
2193
2245
  if (!swipeEnabled) return false;
2194
2246
  const isHorizontal = Math.abs(gestureState.dx) > Math.abs(gestureState.dy);
@@ -2261,18 +2313,11 @@ function PageDrawer({
2261
2313
  }
2262
2314
  ),
2263
2315
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(AppScrollView, { flex: true, className: "px-4 py-4", children }),
2264
- footer && /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
2265
- AppView,
2266
- {
2267
- className: "px-4 py-4",
2268
- style: [styles4.footer, { borderTopColor: colors.divider }],
2269
- children: footer
2270
- }
2271
- )
2316
+ footer && /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(AppView, { className: "px-4 py-4", style: [styles4.footer, { borderTopColor: colors.divider }], children: footer })
2272
2317
  ]
2273
2318
  }
2274
2319
  );
2275
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_react_native12.Modal, { visible: true, transparent: true, animationType: "fade", onRequestClose: handleClose, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(
2320
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_react_native13.Modal, { visible: true, transparent: true, animationType: "fade", onRequestClose: handleClose, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(
2276
2321
  AppView,
2277
2322
  {
2278
2323
  testID,
@@ -2295,7 +2340,7 @@ function PageDrawer({
2295
2340
  }
2296
2341
  ) });
2297
2342
  }
2298
- var styles4 = import_react_native12.StyleSheet.create({
2343
+ var styles4 = import_react_native13.StyleSheet.create({
2299
2344
  drawer: {
2300
2345
  height: "100%"
2301
2346
  },
@@ -2323,7 +2368,7 @@ function GradientView({
2323
2368
 
2324
2369
  // src/ui/form/AppInput.tsx
2325
2370
  var import_react17 = require("react");
2326
- var import_react_native13 = require("react-native");
2371
+ var import_react_native14 = require("react-native");
2327
2372
  var import_jsx_runtime21 = require("nativewind/jsx-runtime");
2328
2373
  var AppInput = (0, import_react17.forwardRef)(
2329
2374
  ({ label, error, disabled = false, leftIcon, rightIcon, className, style, ...props }, ref) => {
@@ -2352,9 +2397,9 @@ var AppInput = (0, import_react17.forwardRef)(
2352
2397
  }
2353
2398
  ],
2354
2399
  children: [
2355
- leftIcon && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_native13.View, { style: styles5.icon, children: leftIcon }),
2400
+ leftIcon && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_native14.View, { style: styles5.icon, children: leftIcon }),
2356
2401
  /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2357
- import_react_native13.TextInput,
2402
+ import_react_native14.TextInput,
2358
2403
  {
2359
2404
  ref,
2360
2405
  className: "flex-1 py-3 text-base",
@@ -2372,7 +2417,7 @@ var AppInput = (0, import_react17.forwardRef)(
2372
2417
  ...props
2373
2418
  }
2374
2419
  ),
2375
- rightIcon && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_native13.View, { style: styles5.icon, children: rightIcon })
2420
+ rightIcon && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react_native14.View, { style: styles5.icon, children: rightIcon })
2376
2421
  ]
2377
2422
  }
2378
2423
  ),
@@ -2381,7 +2426,7 @@ var AppInput = (0, import_react17.forwardRef)(
2381
2426
  }
2382
2427
  );
2383
2428
  AppInput.displayName = "AppInput";
2384
- var styles5 = import_react_native13.StyleSheet.create({
2429
+ var styles5 = import_react_native14.StyleSheet.create({
2385
2430
  inputContainer: {
2386
2431
  borderWidth: 0.5,
2387
2432
  minHeight: 48
@@ -2397,7 +2442,7 @@ var styles5 = import_react_native13.StyleSheet.create({
2397
2442
 
2398
2443
  // src/ui/form/Checkbox.tsx
2399
2444
  var import_react18 = require("react");
2400
- var import_react_native14 = require("react-native");
2445
+ var import_react_native15 = require("react-native");
2401
2446
  var import_jsx_runtime22 = require("nativewind/jsx-runtime");
2402
2447
  function Checkbox({
2403
2448
  checked,
@@ -2421,7 +2466,7 @@ function Checkbox({
2421
2466
  };
2422
2467
  const disabledOpacity = 0.4;
2423
2468
  return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
2424
- import_react_native14.TouchableOpacity,
2469
+ import_react_native15.TouchableOpacity,
2425
2470
  {
2426
2471
  onPress: toggle,
2427
2472
  disabled,
@@ -2452,7 +2497,7 @@ function Checkbox({
2452
2497
  }
2453
2498
  );
2454
2499
  }
2455
- var styles6 = import_react_native14.StyleSheet.create({
2500
+ var styles6 = import_react_native15.StyleSheet.create({
2456
2501
  checkbox: {
2457
2502
  borderWidth: 0.5
2458
2503
  }
@@ -2497,7 +2542,7 @@ function CheckboxGroup({
2497
2542
 
2498
2543
  // src/ui/form/Radio.tsx
2499
2544
  var import_react19 = require("react");
2500
- var import_react_native15 = require("react-native");
2545
+ var import_react_native16 = require("react-native");
2501
2546
  var import_jsx_runtime24 = require("nativewind/jsx-runtime");
2502
2547
  function Radio({
2503
2548
  checked,
@@ -2521,7 +2566,7 @@ function Radio({
2521
2566
  };
2522
2567
  const disabledOpacity = 0.4;
2523
2568
  return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
2524
- import_react_native15.TouchableOpacity,
2569
+ import_react_native16.TouchableOpacity,
2525
2570
  {
2526
2571
  onPress: toggle,
2527
2572
  disabled,
@@ -2556,7 +2601,7 @@ function Radio({
2556
2601
  }
2557
2602
  );
2558
2603
  }
2559
- var styles7 = import_react_native15.StyleSheet.create({
2604
+ var styles7 = import_react_native16.StyleSheet.create({
2560
2605
  radio: {
2561
2606
  borderWidth: 0.5
2562
2607
  },
@@ -2590,7 +2635,7 @@ function RadioGroup({
2590
2635
 
2591
2636
  // src/ui/form/Switch.tsx
2592
2637
  var import_react20 = require("react");
2593
- var import_react_native16 = require("react-native");
2638
+ var import_react_native17 = require("react-native");
2594
2639
  var import_jsx_runtime26 = require("nativewind/jsx-runtime");
2595
2640
  function Switch({
2596
2641
  checked,
@@ -2624,7 +2669,7 @@ function Switch({
2624
2669
  const config = sizes[size];
2625
2670
  const thumbPosition = isChecked ? config.width - config.thumb - config.padding : config.padding;
2626
2671
  return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
2627
- import_react_native16.TouchableOpacity,
2672
+ import_react_native17.TouchableOpacity,
2628
2673
  {
2629
2674
  onPress: toggle,
2630
2675
  disabled,
@@ -2669,7 +2714,7 @@ function Switch({
2669
2714
  }
2670
2715
  );
2671
2716
  }
2672
- var styles8 = import_react_native16.StyleSheet.create({
2717
+ var styles8 = import_react_native17.StyleSheet.create({
2673
2718
  track: {
2674
2719
  justifyContent: "center",
2675
2720
  padding: 2
@@ -2685,7 +2730,7 @@ var styles8 = import_react_native16.StyleSheet.create({
2685
2730
 
2686
2731
  // src/ui/form/Slider.tsx
2687
2732
  var import_react22 = require("react");
2688
- var import_react_native17 = require("react-native");
2733
+ var import_react_native18 = require("react-native");
2689
2734
 
2690
2735
  // src/ui/form/useFormTheme.ts
2691
2736
  var import_react21 = require("react");
@@ -2753,7 +2798,7 @@ function Slider({
2753
2798
  [value, min, max, onChange]
2754
2799
  );
2755
2800
  const panResponder = (0, import_react22.useRef)(
2756
- import_react_native17.PanResponder.create({
2801
+ import_react_native18.PanResponder.create({
2757
2802
  onStartShouldSetPanResponder: () => !disabled,
2758
2803
  onMoveShouldSetPanResponder: () => !disabled,
2759
2804
  onPanResponderGrant: () => {
@@ -2816,7 +2861,7 @@ function Slider({
2816
2861
  }
2817
2862
  ),
2818
2863
  /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
2819
- import_react_native17.View,
2864
+ import_react_native18.View,
2820
2865
  {
2821
2866
  onLayout,
2822
2867
  className: "rounded-full",
@@ -2875,7 +2920,7 @@ function Slider({
2875
2920
  )
2876
2921
  ] });
2877
2922
  }
2878
- var styles9 = import_react_native17.StyleSheet.create({
2923
+ var styles9 = import_react_native18.StyleSheet.create({
2879
2924
  track: {
2880
2925
  height: 6,
2881
2926
  width: "100%"
@@ -2917,8 +2962,11 @@ var styles9 = import_react_native17.StyleSheet.create({
2917
2962
 
2918
2963
  // src/ui/form/Select.tsx
2919
2964
  var import_react23 = require("react");
2920
- var import_react_native18 = require("react-native");
2965
+ var import_react_native19 = require("react-native");
2921
2966
  var import_jsx_runtime28 = require("nativewind/jsx-runtime");
2967
+ function formatSelectedCountText(template, count) {
2968
+ return template.replace("{{count}}", String(count));
2969
+ }
2922
2970
  function Select({
2923
2971
  value,
2924
2972
  onChange,
@@ -2929,6 +2977,12 @@ function Select({
2929
2977
  onSearch,
2930
2978
  disabled = false,
2931
2979
  clearable = true,
2980
+ singleSelectTitle = "\u8BF7\u9009\u62E9",
2981
+ multipleSelectTitle = "\u9009\u62E9\u9009\u9879",
2982
+ searchPlaceholder = "\u641C\u7D22...",
2983
+ emptyText = "\u6682\u65E0\u9009\u9879",
2984
+ selectedCountText = "\u5DF2\u9009\u62E9 {{count}} \u9879",
2985
+ confirmText = "\u786E\u5B9A",
2932
2986
  className
2933
2987
  }) {
2934
2988
  const colors = useFormThemeColors();
@@ -3023,15 +3077,15 @@ function Select({
3023
3077
  children: displayText
3024
3078
  }
3025
3079
  ),
3026
- /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_react_native18.View, { className: "flex-row items-center", children: [
3027
- clearable && selectedValues.length > 0 && !disabled && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native18.TouchableOpacity, { onPress: handleClear, className: "mr-2 p-1", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "close", size: "sm", color: colors.icon }) }),
3080
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_react_native19.View, { className: "flex-row items-center", children: [
3081
+ clearable && selectedValues.length > 0 && !disabled && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native19.TouchableOpacity, { onPress: handleClear, className: "mr-2 p-1", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "close", size: "sm", color: colors.icon }) }),
3028
3082
  /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "keyboard-arrow-down", size: "md", color: colors.icon })
3029
3083
  ] })
3030
3084
  ]
3031
3085
  }
3032
3086
  ),
3033
3087
  /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3034
- import_react_native18.Modal,
3088
+ import_react_native19.Modal,
3035
3089
  {
3036
3090
  visible,
3037
3091
  transparent: true,
@@ -3052,8 +3106,8 @@ function Select({
3052
3106
  className: "px-4 py-3",
3053
3107
  style: [styles10.header, { borderBottomColor: colors.divider }],
3054
3108
  children: [
3055
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppText, { className: "text-lg font-semibold", style: { color: colors.text }, children: multiple ? "\u9009\u62E9\u9009\u9879" : "\u8BF7\u9009\u62E9" }),
3056
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native18.TouchableOpacity, { onPress: () => setVisible(false), children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "close", size: "md", color: colors.icon }) })
3109
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppText, { className: "text-lg font-semibold", style: { color: colors.text }, children: multiple ? multipleSelectTitle : singleSelectTitle }),
3110
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native19.TouchableOpacity, { onPress: () => setVisible(false), children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "close", size: "md", color: colors.icon }) })
3057
3111
  ]
3058
3112
  }
3059
3113
  ),
@@ -3070,32 +3124,32 @@ function Select({
3070
3124
  className: "px-3 py-2 rounded-lg",
3071
3125
  style: { backgroundColor: colors.surfaceMuted },
3072
3126
  children: [
3073
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native18.View, { style: { marginRight: 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "search", size: "sm", color: colors.icon }) }),
3127
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native19.View, { style: { marginRight: 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "search", size: "sm", color: colors.icon }) }),
3074
3128
  /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3075
- import_react_native18.TextInput,
3129
+ import_react_native19.TextInput,
3076
3130
  {
3077
3131
  className: "flex-1 text-base",
3078
3132
  style: { color: colors.text },
3079
- placeholder: "\u641C\u7D22...",
3133
+ placeholder: searchPlaceholder,
3080
3134
  placeholderTextColor: colors.textMuted,
3081
3135
  value: searchKeyword,
3082
3136
  onChangeText: handleSearch,
3083
3137
  autoFocus: true
3084
3138
  }
3085
3139
  ),
3086
- searchKeyword.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native18.TouchableOpacity, { onPress: () => setSearchKeyword(""), children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "close", size: "sm", color: colors.icon }) })
3140
+ searchKeyword.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native19.TouchableOpacity, { onPress: () => setSearchKeyword(""), children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { name: "close", size: "sm", color: colors.icon }) })
3087
3141
  ]
3088
3142
  }
3089
3143
  )
3090
3144
  }
3091
3145
  ),
3092
3146
  /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3093
- import_react_native18.FlatList,
3147
+ import_react_native19.FlatList,
3094
3148
  {
3095
3149
  data: filteredOptions,
3096
3150
  keyExtractor: (item) => item.value,
3097
3151
  renderItem: renderOption,
3098
- ListEmptyComponent: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppView, { center: true, className: "py-8", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppText, { style: { color: colors.textMuted }, children: "\u6682\u65E0\u9009\u9879" }) })
3152
+ ListEmptyComponent: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppView, { center: true, className: "py-8", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppText, { style: { color: colors.textMuted }, children: emptyText }) })
3099
3153
  }
3100
3154
  ),
3101
3155
  multiple && /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
@@ -3107,18 +3161,14 @@ function Select({
3107
3161
  className: "px-4 py-3",
3108
3162
  style: [styles10.footer, { borderTopColor: colors.divider }],
3109
3163
  children: [
3110
- /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(AppText, { style: { color: colors.textMuted }, children: [
3111
- "\u5DF2\u9009\u62E9 ",
3112
- selectedValues.length,
3113
- " \u9879"
3114
- ] }),
3164
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppText, { style: { color: colors.textMuted }, children: formatSelectedCountText(selectedCountText, selectedValues.length) }),
3115
3165
  /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3116
- import_react_native18.TouchableOpacity,
3166
+ import_react_native19.TouchableOpacity,
3117
3167
  {
3118
3168
  className: "px-4 py-2 rounded-lg",
3119
3169
  style: { backgroundColor: colors.primary },
3120
3170
  onPress: () => setVisible(false),
3121
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppText, { className: "font-medium", style: { color: colors.textInverse }, children: "\u786E\u5B9A" })
3171
+ children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(AppText, { className: "font-medium", style: { color: colors.textInverse }, children: confirmText })
3122
3172
  }
3123
3173
  )
3124
3174
  ]
@@ -3131,7 +3181,7 @@ function Select({
3131
3181
  )
3132
3182
  ] });
3133
3183
  }
3134
- var styles10 = import_react_native18.StyleSheet.create({
3184
+ var styles10 = import_react_native19.StyleSheet.create({
3135
3185
  trigger: {
3136
3186
  borderWidth: 0.5
3137
3187
  },
@@ -3151,7 +3201,7 @@ var styles10 = import_react_native18.StyleSheet.create({
3151
3201
 
3152
3202
  // src/ui/form/DatePicker.tsx
3153
3203
  var import_react24 = require("react");
3154
- var import_react_native19 = require("react-native");
3204
+ var import_react_native20 = require("react-native");
3155
3205
  var import_jsx_runtime29 = require("nativewind/jsx-runtime");
3156
3206
  function PickerColumn({
3157
3207
  title,
@@ -3177,7 +3227,7 @@ function PickerColumn({
3177
3227
  const selected = selectedValue === value;
3178
3228
  const disabled = isDisabled(value);
3179
3229
  return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3180
- import_react_native19.TouchableOpacity,
3230
+ import_react_native20.TouchableOpacity,
3181
3231
  {
3182
3232
  className: cn("py-2 items-center", selected && "bg-primary-50"),
3183
3233
  style: selected ? { backgroundColor: colors.primarySurface } : void 0,
@@ -3209,7 +3259,17 @@ function DatePicker({
3209
3259
  format = "yyyy-MM-dd",
3210
3260
  minDate,
3211
3261
  maxDate,
3212
- className
3262
+ className,
3263
+ cancelText = "\u53D6\u6D88",
3264
+ confirmText = "\u786E\u5B9A",
3265
+ pickerTitle = "\u9009\u62E9\u65E5\u671F",
3266
+ pickerDateFormat = "yyyy\u5E74MM\u6708dd\u65E5",
3267
+ yearLabel = "\u5E74",
3268
+ monthLabel = "\u6708",
3269
+ dayLabel = "\u65E5",
3270
+ todayText = "\u4ECA\u5929",
3271
+ minDateText = "\u6700\u65E9",
3272
+ maxDateText = "\u6700\u665A"
3213
3273
  }) {
3214
3274
  const colors = useFormThemeColors();
3215
3275
  const [visible, setVisible] = (0, import_react24.useState)(false);
@@ -3287,7 +3347,7 @@ function DatePicker({
3287
3347
  }
3288
3348
  ),
3289
3349
  /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3290
- import_react_native19.Modal,
3350
+ import_react_native20.Modal,
3291
3351
  {
3292
3352
  visible,
3293
3353
  transparent: true,
@@ -3303,18 +3363,18 @@ function DatePicker({
3303
3363
  className: "px-4 py-3",
3304
3364
  style: [styles11.header, { borderBottomColor: colors.divider }],
3305
3365
  children: [
3306
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_native19.TouchableOpacity, { onPress: () => setVisible(false), children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.textMuted }, children: "\u53D6\u6D88" }) }),
3307
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { className: "text-lg font-semibold", style: { color: colors.text }, children: "\u9009\u62E9\u65E5\u671F" }),
3308
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_native19.TouchableOpacity, { onPress: handleConfirm, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.primary }, className: "font-medium", children: "\u786E\u5B9A" }) })
3366
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_native20.TouchableOpacity, { onPress: () => setVisible(false), children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.textMuted }, children: cancelText }) }),
3367
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { className: "text-lg font-semibold", style: { color: colors.text }, children: pickerTitle }),
3368
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_native20.TouchableOpacity, { onPress: handleConfirm, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.primary }, className: "font-medium", children: confirmText }) })
3309
3369
  ]
3310
3370
  }
3311
3371
  ),
3312
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppView, { center: true, className: "py-4", style: { backgroundColor: colors.headerSurface }, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { className: "text-2xl font-semibold", style: { color: colors.text }, children: formatDate(tempDate, "yyyy\u5E74MM\u6708dd\u65E5") }) }),
3372
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppView, { center: true, className: "py-4", style: { backgroundColor: colors.headerSurface }, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { className: "text-2xl font-semibold", style: { color: colors.text }, children: formatDate(tempDate, pickerDateFormat) }) }),
3313
3373
  /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(AppView, { row: true, className: "h-48", children: [
3314
3374
  /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3315
3375
  PickerColumn,
3316
3376
  {
3317
- title: "\u5E74",
3377
+ title: yearLabel,
3318
3378
  values: years,
3319
3379
  selectedValue: tempDate.getFullYear(),
3320
3380
  onSelect: (year) => updateTempDate(year),
@@ -3326,7 +3386,7 @@ function DatePicker({
3326
3386
  /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3327
3387
  PickerColumn,
3328
3388
  {
3329
- title: "\u6708",
3389
+ title: monthLabel,
3330
3390
  values: months,
3331
3391
  selectedValue: tempDate.getMonth() + 1,
3332
3392
  onSelect: (month) => updateTempDate(void 0, month),
@@ -3339,7 +3399,7 @@ function DatePicker({
3339
3399
  /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3340
3400
  PickerColumn,
3341
3401
  {
3342
- title: "\u65E5",
3402
+ title: dayLabel,
3343
3403
  values: days,
3344
3404
  selectedValue: tempDate.getDate(),
3345
3405
  onSelect: (day) => updateTempDate(void 0, void 0, day),
@@ -3356,30 +3416,30 @@ function DatePicker({
3356
3416
  style: [styles11.footer, { borderTopColor: colors.divider }],
3357
3417
  children: [
3358
3418
  /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3359
- import_react_native19.TouchableOpacity,
3419
+ import_react_native20.TouchableOpacity,
3360
3420
  {
3361
3421
  className: "flex-1 py-2 items-center rounded-lg",
3362
3422
  style: { backgroundColor: colors.surfaceMuted },
3363
3423
  onPress: () => setTempDate(/* @__PURE__ */ new Date()),
3364
- children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.text }, children: "\u4ECA\u5929" })
3424
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.text }, children: todayText })
3365
3425
  }
3366
3426
  ),
3367
3427
  minDate && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3368
- import_react_native19.TouchableOpacity,
3428
+ import_react_native20.TouchableOpacity,
3369
3429
  {
3370
3430
  className: "flex-1 py-2 items-center rounded-lg",
3371
3431
  style: { backgroundColor: colors.surfaceMuted },
3372
3432
  onPress: () => setTempDate(minDate),
3373
- children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.text }, children: "\u6700\u65E9" })
3433
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.text }, children: minDateText })
3374
3434
  }
3375
3435
  ),
3376
3436
  maxDate && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3377
- import_react_native19.TouchableOpacity,
3437
+ import_react_native20.TouchableOpacity,
3378
3438
  {
3379
3439
  className: "flex-1 py-2 items-center rounded-lg",
3380
3440
  style: { backgroundColor: colors.surfaceMuted },
3381
3441
  onPress: () => setTempDate(maxDate),
3382
- children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.text }, children: "\u6700\u665A" })
3442
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(AppText, { style: { color: colors.text }, children: maxDateText })
3383
3443
  }
3384
3444
  )
3385
3445
  ]
@@ -3390,7 +3450,7 @@ function DatePicker({
3390
3450
  )
3391
3451
  ] });
3392
3452
  }
3393
- var styles11 = import_react_native19.StyleSheet.create({
3453
+ var styles11 = import_react_native20.StyleSheet.create({
3394
3454
  trigger: {
3395
3455
  borderWidth: 0.5
3396
3456
  },
@@ -3625,7 +3685,7 @@ function useThrottle(value, delay = 200) {
3625
3685
 
3626
3686
  // src/ui/hooks/useKeyboard.ts
3627
3687
  var import_react30 = require("react");
3628
- var import_react_native20 = require("react-native");
3688
+ var import_react_native21 = require("react-native");
3629
3689
  function useKeyboard() {
3630
3690
  const [visible, setVisible] = (0, import_react30.useState)(false);
3631
3691
  const [height, setHeight] = (0, import_react30.useState)(0);
@@ -3646,13 +3706,13 @@ function useKeyboard() {
3646
3706
  setVisible(false);
3647
3707
  setHeight(0);
3648
3708
  };
3649
- const willShowSub = import_react_native20.Keyboard.addListener(
3650
- import_react_native20.Platform.OS === "ios" ? "keyboardWillShow" : "keyboardDidShow",
3651
- import_react_native20.Platform.OS === "ios" ? handleKeyboardWillShow : handleKeyboardDidShow
3709
+ const willShowSub = import_react_native21.Keyboard.addListener(
3710
+ import_react_native21.Platform.OS === "ios" ? "keyboardWillShow" : "keyboardDidShow",
3711
+ import_react_native21.Platform.OS === "ios" ? handleKeyboardWillShow : handleKeyboardDidShow
3652
3712
  );
3653
- const willHideSub = import_react_native20.Keyboard.addListener(
3654
- import_react_native20.Platform.OS === "ios" ? "keyboardWillHide" : "keyboardDidHide",
3655
- import_react_native20.Platform.OS === "ios" ? handleKeyboardWillHide : handleKeyboardDidHide
3713
+ const willHideSub = import_react_native21.Keyboard.addListener(
3714
+ import_react_native21.Platform.OS === "ios" ? "keyboardWillHide" : "keyboardDidHide",
3715
+ import_react_native21.Platform.OS === "ios" ? handleKeyboardWillHide : handleKeyboardDidHide
3656
3716
  );
3657
3717
  return () => {
3658
3718
  willShowSub.remove();
@@ -3660,17 +3720,17 @@ function useKeyboard() {
3660
3720
  };
3661
3721
  }, []);
3662
3722
  const dismiss = (0, import_react30.useCallback)(() => {
3663
- import_react_native20.Keyboard.dismiss();
3723
+ import_react_native21.Keyboard.dismiss();
3664
3724
  }, []);
3665
3725
  return { visible, height, dismiss };
3666
3726
  }
3667
3727
 
3668
3728
  // src/ui/hooks/useDimensions.ts
3669
3729
  var import_react31 = require("react");
3670
- var import_react_native21 = require("react-native");
3730
+ var import_react_native22 = require("react-native");
3671
3731
  function useDimensions() {
3672
3732
  const [dimensions, setDimensions] = (0, import_react31.useState)(() => {
3673
- const window = import_react_native21.Dimensions.get("window");
3733
+ const window = import_react_native22.Dimensions.get("window");
3674
3734
  return {
3675
3735
  width: window.width,
3676
3736
  height: window.height,
@@ -3687,7 +3747,7 @@ function useDimensions() {
3687
3747
  fontScale: window.fontScale
3688
3748
  });
3689
3749
  };
3690
- const subscription = import_react_native21.Dimensions.addEventListener("change", handleChange);
3750
+ const subscription = import_react_native22.Dimensions.addEventListener("change", handleChange);
3691
3751
  return () => {
3692
3752
  subscription.remove();
3693
3753
  };
@@ -3697,10 +3757,10 @@ function useDimensions() {
3697
3757
 
3698
3758
  // src/ui/hooks/useOrientation.ts
3699
3759
  var import_react32 = require("react");
3700
- var import_react_native22 = require("react-native");
3760
+ var import_react_native23 = require("react-native");
3701
3761
  function useOrientation() {
3702
3762
  const getOrientation = () => {
3703
- const { width, height } = import_react_native22.Dimensions.get("window");
3763
+ const { width, height } = import_react_native23.Dimensions.get("window");
3704
3764
  return width > height ? "landscape" : "portrait";
3705
3765
  };
3706
3766
  const [orientation, setOrientation] = (0, import_react32.useState)(getOrientation);
@@ -3709,7 +3769,7 @@ function useOrientation() {
3709
3769
  const newOrientation = window.width > window.height ? "landscape" : "portrait";
3710
3770
  setOrientation(newOrientation);
3711
3771
  };
3712
- const subscription = import_react_native22.Dimensions.addEventListener("change", handleChange);
3772
+ const subscription = import_react_native23.Dimensions.addEventListener("change", handleChange);
3713
3773
  return () => {
3714
3774
  subscription.remove();
3715
3775
  };
@@ -3817,7 +3877,7 @@ var import_react34 = __toESM(require("react"));
3817
3877
  var import_bottom_tabs = require("@react-navigation/bottom-tabs");
3818
3878
 
3819
3879
  // src/navigation/components/BottomTabBar.tsx
3820
- var import_react_native23 = require("react-native");
3880
+ var import_react_native24 = require("react-native");
3821
3881
  var import_react_native_safe_area_context2 = require("react-native-safe-area-context");
3822
3882
  var import_jsx_runtime33 = require("nativewind/jsx-runtime");
3823
3883
  var DEFAULT_TAB_BAR_HEIGHT = 65;
@@ -3842,7 +3902,7 @@ function BottomTabBar({
3842
3902
  const backgroundColor = style?.backgroundColor || colors.card;
3843
3903
  const borderTopColor = colors.divider;
3844
3904
  return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
3845
- import_react_native23.View,
3905
+ import_react_native24.View,
3846
3906
  {
3847
3907
  style: [
3848
3908
  styles12.container,
@@ -3877,7 +3937,7 @@ function BottomTabBar({
3877
3937
  }) : null;
3878
3938
  const badge = options.tabBarBadge;
3879
3939
  return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(
3880
- import_react_native23.TouchableOpacity,
3940
+ import_react_native24.TouchableOpacity,
3881
3941
  {
3882
3942
  accessibilityRole: "button",
3883
3943
  accessibilityState: isFocused ? { selected: true } : {},
@@ -3892,9 +3952,9 @@ function BottomTabBar({
3892
3952
  }
3893
3953
  ],
3894
3954
  children: [
3895
- /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_react_native23.View, { style: [styles12.iconContainer, iconStyle], children: [
3955
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_react_native24.View, { style: [styles12.iconContainer, iconStyle], children: [
3896
3956
  iconName,
3897
- badge != null && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react_native23.View, { style: [styles12.badge, { backgroundColor: activeColor }], children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(AppText, { style: styles12.badgeText, children: typeof badge === "number" && badge > 99 ? "99+" : badge }) })
3957
+ badge != null && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react_native24.View, { style: [styles12.badge, { backgroundColor: activeColor }], children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(AppText, { style: styles12.badgeText, children: typeof badge === "number" && badge > 99 ? "99+" : badge }) })
3898
3958
  ] }),
3899
3959
  showLabel && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
3900
3960
  AppText,
@@ -3916,7 +3976,7 @@ function BottomTabBar({
3916
3976
  }
3917
3977
  );
3918
3978
  }
3919
- var styles12 = import_react_native23.StyleSheet.create({
3979
+ var styles12 = import_react_native24.StyleSheet.create({
3920
3980
  container: {
3921
3981
  flexDirection: "row",
3922
3982
  borderTopWidth: 0.5,
@@ -4116,7 +4176,7 @@ function createDrawerScreens(routes) {
4116
4176
  }
4117
4177
 
4118
4178
  // src/navigation/components/AppHeader.tsx
4119
- var import_react_native24 = require("react-native");
4179
+ var import_react_native25 = require("react-native");
4120
4180
  var import_react_native_safe_area_context3 = require("react-native-safe-area-context");
4121
4181
  var import_jsx_runtime36 = require("nativewind/jsx-runtime");
4122
4182
  function AppHeader({
@@ -4173,7 +4233,7 @@ function AppHeader({
4173
4233
  }
4174
4234
  );
4175
4235
  }
4176
- var styles13 = import_react_native24.StyleSheet.create({
4236
+ var styles13 = import_react_native25.StyleSheet.create({
4177
4237
  container: {
4178
4238
  height: 44
4179
4239
  // iOS 标准导航栏高度
@@ -4224,7 +4284,7 @@ var styles13 = import_react_native24.StyleSheet.create({
4224
4284
  });
4225
4285
 
4226
4286
  // src/navigation/components/DrawerContent.tsx
4227
- var import_react_native25 = require("react-native");
4287
+ var import_react_native26 = require("react-native");
4228
4288
  var import_drawer2 = require("@react-navigation/drawer");
4229
4289
  var import_jsx_runtime37 = require("nativewind/jsx-runtime");
4230
4290
  function DrawerContent({
@@ -4256,19 +4316,19 @@ function DrawerContent({
4256
4316
  };
4257
4317
  });
4258
4318
  return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_drawer2.DrawerContentScrollView, { style: [styles14.container, { backgroundColor }], children: [
4259
- header && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native25.View, { style: [styles14.header, { borderBottomColor: dividerColor }], children: header }),
4319
+ header && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native26.View, { style: [styles14.header, { borderBottomColor: dividerColor }], children: header }),
4260
4320
  /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(AppView, { className: "py-2", children: drawerItems.map((item) => {
4261
4321
  const isFocused = state.routes[state.index].name === item.name;
4262
4322
  const onPress = () => {
4263
4323
  navigation.navigate(item.name);
4264
4324
  };
4265
4325
  return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
4266
- import_react_native25.TouchableOpacity,
4326
+ import_react_native26.TouchableOpacity,
4267
4327
  {
4268
4328
  onPress,
4269
4329
  style: [styles14.item, isFocused && { backgroundColor: activeBgColor }],
4270
4330
  children: [
4271
- item.icon && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native25.View, { style: styles14.iconContainer, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4331
+ item.icon && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native26.View, { style: styles14.iconContainer, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4272
4332
  Icon,
4273
4333
  {
4274
4334
  name: item.icon,
@@ -4288,16 +4348,16 @@ function DrawerContent({
4288
4348
  children: item.label
4289
4349
  }
4290
4350
  ),
4291
- item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native25.View, { style: [styles14.badge, { backgroundColor: activeColor }], children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(AppText, { style: styles14.badgeText, children: typeof item.badge === "number" && item.badge > 99 ? "99+" : item.badge }) })
4351
+ item.badge != null && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native26.View, { style: [styles14.badge, { backgroundColor: activeColor }], children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(AppText, { style: styles14.badgeText, children: typeof item.badge === "number" && item.badge > 99 ? "99+" : item.badge }) })
4292
4352
  ]
4293
4353
  },
4294
4354
  item.name
4295
4355
  );
4296
4356
  }) }),
4297
- footer && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native25.View, { style: [styles14.footer, { borderTopColor: dividerColor }], children: footer })
4357
+ footer && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native26.View, { style: [styles14.footer, { borderTopColor: dividerColor }], children: footer })
4298
4358
  ] });
4299
4359
  }
4300
- var styles14 = import_react_native25.StyleSheet.create({
4360
+ var styles14 = import_react_native26.StyleSheet.create({
4301
4361
  container: {
4302
4362
  flex: 1
4303
4363
  },
@@ -4392,7 +4452,8 @@ var import_native5 = require("@react-navigation/native");
4392
4452
  var import_react_native_safe_area_context4 = require("react-native-safe-area-context");
4393
4453
 
4394
4454
  // src/overlay/AppStatusBar.tsx
4395
- var import_react_native26 = require("react-native");
4455
+ var import_react_native27 = require("react-native");
4456
+ var import_native6 = require("@react-navigation/native");
4396
4457
  var import_jsx_runtime38 = require("nativewind/jsx-runtime");
4397
4458
  function AppStatusBar({
4398
4459
  barStyle = "auto",
@@ -4404,7 +4465,7 @@ function AppStatusBar({
4404
4465
  const resolvedBarStyle = barStyle === "auto" ? isDark ? "light-content" : "dark-content" : barStyle;
4405
4466
  const resolvedBackgroundColor = backgroundColor ?? (translucent ? "transparent" : theme.colors.background?.[500] || "#ffffff");
4406
4467
  return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
4407
- import_react_native26.StatusBar,
4468
+ import_react_native27.StatusBar,
4408
4469
  {
4409
4470
  barStyle: resolvedBarStyle,
4410
4471
  backgroundColor: resolvedBackgroundColor,
@@ -4413,6 +4474,11 @@ function AppStatusBar({
4413
4474
  }
4414
4475
  );
4415
4476
  }
4477
+ function AppFocusedStatusBar(props) {
4478
+ const isFocused = (0, import_native6.useIsFocused)();
4479
+ if (!isFocused) return null;
4480
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(AppStatusBar, { ...props });
4481
+ }
4416
4482
 
4417
4483
  // src/overlay/loading/provider.tsx
4418
4484
  var import_react38 = require("react");
@@ -4427,15 +4493,15 @@ function useLoadingContext() {
4427
4493
  }
4428
4494
 
4429
4495
  // src/overlay/loading/component.tsx
4430
- var import_react_native27 = require("react-native");
4496
+ var import_react_native28 = require("react-native");
4431
4497
  var import_jsx_runtime39 = require("nativewind/jsx-runtime");
4432
4498
  function LoadingModal({ visible, text }) {
4433
- return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native27.Modal, { transparent: true, visible, animationType: "fade", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native27.View, { style: styles15.overlay, children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native27.View, { style: [styles15.loadingBox, { backgroundColor: "rgba(0,0,0,0.8)" }], children: [
4434
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native27.ActivityIndicator, { size: "large", color: "#fff" }),
4499
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native28.Modal, { transparent: true, visible, animationType: "fade", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native28.View, { style: styles15.overlay, children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native28.View, { style: [styles15.loadingBox, { backgroundColor: "rgba(0,0,0,0.8)" }], children: [
4500
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native28.ActivityIndicator, { size: "large", color: "#fff" }),
4435
4501
  text && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(AppText, { className: "text-white mt-3 text-sm", children: text })
4436
4502
  ] }) }) });
4437
4503
  }
4438
- var styles15 = import_react_native27.StyleSheet.create({
4504
+ var styles15 = import_react_native28.StyleSheet.create({
4439
4505
  overlay: {
4440
4506
  flex: 1,
4441
4507
  backgroundColor: "rgba(0,0,0,0.5)",
@@ -4468,7 +4534,7 @@ function LoadingProvider({ children }) {
4468
4534
 
4469
4535
  // src/overlay/toast/provider.tsx
4470
4536
  var import_react41 = require("react");
4471
- var import_react_native29 = require("react-native");
4537
+ var import_react_native30 = require("react-native");
4472
4538
 
4473
4539
  // src/overlay/toast/context.ts
4474
4540
  var import_react39 = require("react");
@@ -4481,15 +4547,15 @@ function useToastContext() {
4481
4547
 
4482
4548
  // src/overlay/toast/component.tsx
4483
4549
  var import_react40 = require("react");
4484
- var import_react_native28 = require("react-native");
4550
+ var import_react_native29 = require("react-native");
4485
4551
  var import_jsx_runtime41 = require("nativewind/jsx-runtime");
4486
4552
  function ToastItemView({ message, type, onHide }) {
4487
- const fadeAnim = (0, import_react40.useRef)(new import_react_native28.Animated.Value(0)).current;
4553
+ const fadeAnim = (0, import_react40.useRef)(new import_react_native29.Animated.Value(0)).current;
4488
4554
  (0, import_react40.useEffect)(() => {
4489
- import_react_native28.Animated.sequence([
4490
- import_react_native28.Animated.timing(fadeAnim, { toValue: 1, duration: 200, useNativeDriver: true }),
4491
- import_react_native28.Animated.delay(2500),
4492
- import_react_native28.Animated.timing(fadeAnim, { toValue: 0, duration: 200, useNativeDriver: true })
4555
+ import_react_native29.Animated.sequence([
4556
+ import_react_native29.Animated.timing(fadeAnim, { toValue: 1, duration: 200, useNativeDriver: true }),
4557
+ import_react_native29.Animated.delay(2500),
4558
+ import_react_native29.Animated.timing(fadeAnim, { toValue: 0, duration: 200, useNativeDriver: true })
4493
4559
  ]).start(onHide);
4494
4560
  }, []);
4495
4561
  const bgColors = {
@@ -4499,7 +4565,7 @@ function ToastItemView({ message, type, onHide }) {
4499
4565
  info: "bg-primary-500"
4500
4566
  };
4501
4567
  return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
4502
- import_react_native28.Animated.View,
4568
+ import_react_native29.Animated.View,
4503
4569
  {
4504
4570
  style: {
4505
4571
  opacity: fadeAnim,
@@ -4558,10 +4624,10 @@ function ToastProvider({ children }) {
4558
4624
  );
4559
4625
  return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(ToastContext.Provider, { value: { show, success, error, info, warning }, children: [
4560
4626
  children,
4561
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_native29.View, { style: styles16.toastContainer, pointerEvents: "none", children: toasts.map((toast) => /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ToastItemView, { ...toast, onHide: () => remove(toast.id) }, toast.id)) })
4627
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_native30.View, { style: styles16.toastContainer, pointerEvents: "none", children: toasts.map((toast) => /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(ToastItemView, { ...toast, onHide: () => remove(toast.id) }, toast.id)) })
4562
4628
  ] });
4563
4629
  }
4564
- var styles16 = import_react_native29.StyleSheet.create({
4630
+ var styles16 = import_react_native30.StyleSheet.create({
4565
4631
  toastContainer: {
4566
4632
  position: "absolute",
4567
4633
  top: 60,
@@ -4584,7 +4650,7 @@ function useAlertContext() {
4584
4650
  }
4585
4651
 
4586
4652
  // src/overlay/alert/component.tsx
4587
- var import_react_native30 = require("react-native");
4653
+ var import_react_native31 = require("react-native");
4588
4654
  var import_jsx_runtime43 = require("nativewind/jsx-runtime");
4589
4655
  function AlertModal({
4590
4656
  visible,
@@ -4597,7 +4663,7 @@ function AlertModal({
4597
4663
  onCancel
4598
4664
  }) {
4599
4665
  if (!visible) return null;
4600
- return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react_native30.Modal, { transparent: true, visible: true, animationType: "fade", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react_native30.View, { style: styles17.overlay, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(import_react_native30.View, { style: styles17.alertBox, children: [
4666
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react_native31.Modal, { transparent: true, visible: true, animationType: "fade", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react_native31.View, { style: styles17.overlay, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(import_react_native31.View, { style: styles17.alertBox, children: [
4601
4667
  title && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(AppText, { className: "text-lg font-semibold text-center mb-2", children: title }),
4602
4668
  message && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(AppText, { className: "text-gray-600 text-center mb-4", children: message }),
4603
4669
  /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(AppView, { row: true, gap: 3, className: "mt-2", children: [
@@ -4606,7 +4672,7 @@ function AlertModal({
4606
4672
  ] })
4607
4673
  ] }) }) });
4608
4674
  }
4609
- var styles17 = import_react_native30.StyleSheet.create({
4675
+ var styles17 = import_react_native31.StyleSheet.create({
4610
4676
  overlay: {
4611
4677
  flex: 1,
4612
4678
  backgroundColor: "rgba(0,0,0,0.5)",
@@ -4752,12 +4818,14 @@ var import_react_native_safe_area_context5 = require("react-native-safe-area-con
4752
4818
  ActionIcons,
4753
4819
  Alert,
4754
4820
  AppButton,
4821
+ AppFocusedStatusBar,
4755
4822
  AppHeader,
4756
4823
  AppImage,
4757
4824
  AppInput,
4758
4825
  AppList,
4759
4826
  AppPressable,
4760
4827
  AppProvider,
4828
+ AppScreen,
4761
4829
  AppScrollView,
4762
4830
  AppStatusBar,
4763
4831
  AppText,
@@ -4782,7 +4850,6 @@ var import_react_native_safe_area_context5 = require("react-native-safe-area-con
4782
4850
  NavigationIcons,
4783
4851
  NavigationProvider,
4784
4852
  OverlayProvider,
4785
- Page,
4786
4853
  PageDrawer,
4787
4854
  Progress,
4788
4855
  Radio,