@mrmeg/expo-ui 0.27.1 → 0.28.0

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 (140) hide show
  1. package/CHANGELOG.md +598 -0
  2. package/LLM_USAGE.md +233 -35
  3. package/README.md +504 -103
  4. package/dist/components/Accordion.js +12 -6
  5. package/dist/components/AnimatedView.d.ts +1 -1
  6. package/dist/components/AnimatedView.js +5 -2
  7. package/dist/components/Avatar.d.ts +1 -1
  8. package/dist/components/Avatar.js +2 -2
  9. package/dist/components/Badge.js +5 -1
  10. package/dist/components/BottomSheet.d.ts +29 -1
  11. package/dist/components/BottomSheet.js +107 -30
  12. package/dist/components/Button.d.ts +20 -4
  13. package/dist/components/Button.js +60 -43
  14. package/dist/components/Card.d.ts +1 -1
  15. package/dist/components/Card.js +24 -4
  16. package/dist/components/Carousel.js +2 -2
  17. package/dist/components/Checkbox.js +51 -44
  18. package/dist/components/Collapsible.js +7 -3
  19. package/dist/components/Dialog.js +87 -16
  20. package/dist/components/Drawer.d.ts +1 -1
  21. package/dist/components/Drawer.js +65 -55
  22. package/dist/components/DropdownMenu.js +11 -7
  23. package/dist/components/EmptyState.d.ts +2 -2
  24. package/dist/components/EmptyState.js +5 -2
  25. package/dist/components/Hydrated.d.ts +31 -0
  26. package/dist/components/Hydrated.js +30 -0
  27. package/dist/components/Icon.d.ts +17 -5
  28. package/dist/components/Icon.js +31 -10
  29. package/dist/components/InputOTP.js +5 -2
  30. package/dist/components/Item.d.ts +103 -4
  31. package/dist/components/Item.js +168 -15
  32. package/dist/components/KeyboardAvoidingView.d.ts +1 -1
  33. package/dist/components/KeyboardAvoidingView.js +4 -1
  34. package/dist/components/Label.js +3 -2
  35. package/dist/components/MaxWidthContainer.js +1 -1
  36. package/dist/components/Notification.js +45 -27
  37. package/dist/components/Popover.d.ts +18 -5
  38. package/dist/components/Popover.js +72 -8
  39. package/dist/components/Progress.js +8 -6
  40. package/dist/components/RadioGroup.js +52 -49
  41. package/dist/components/Screen.d.ts +61 -0
  42. package/dist/components/Screen.js +62 -0
  43. package/dist/components/SectionHeader.d.ts +1 -1
  44. package/dist/components/SegmentedControl.d.ts +12 -4
  45. package/dist/components/SegmentedControl.js +94 -4
  46. package/dist/components/Select.js +21 -26
  47. package/dist/components/Skeleton.js +24 -10
  48. package/dist/components/Slider.d.ts +11 -3
  49. package/dist/components/Slider.js +73 -6
  50. package/dist/components/StatCard.d.ts +4 -2
  51. package/dist/components/StatCard.js +3 -1
  52. package/dist/components/StyledText.d.ts +7 -1
  53. package/dist/components/StyledText.js +5 -3
  54. package/dist/components/Switch.d.ts +1 -1
  55. package/dist/components/Switch.js +20 -30
  56. package/dist/components/Tabs.d.ts +2 -2
  57. package/dist/components/Tabs.js +13 -24
  58. package/dist/components/TextInput.d.ts +1 -1
  59. package/dist/components/TextInput.js +71 -26
  60. package/dist/components/Toggle.d.ts +2 -42
  61. package/dist/components/Toggle.js +38 -27
  62. package/dist/components/ToggleGroup.d.ts +1 -1
  63. package/dist/components/ToggleGroup.js +37 -32
  64. package/dist/components/Tooltip.d.ts +1 -1
  65. package/dist/components/Tooltip.js +9 -3
  66. package/dist/components/UIProvider.d.ts +22 -2
  67. package/dist/components/UIProvider.js +15 -3
  68. package/dist/components/bottomSheetDismiss.d.ts +19 -0
  69. package/dist/components/bottomSheetDismiss.js +44 -0
  70. package/dist/components/index.d.ts +46 -44
  71. package/dist/components/index.js +2 -0
  72. package/dist/components/keyboardDismiss.js +12 -4
  73. package/dist/components/nativeTextField.android.js +13 -9
  74. package/dist/constants/colors.d.ts +40 -5
  75. package/dist/constants/colors.js +26 -8
  76. package/dist/constants/fonts.d.ts +41 -2
  77. package/dist/constants/fonts.js +46 -7
  78. package/dist/constants/index.d.ts +5 -4
  79. package/dist/constants/index.js +1 -0
  80. package/dist/constants/interaction.d.ts +18 -0
  81. package/dist/constants/interaction.js +18 -0
  82. package/dist/constants/spacing.d.ts +2 -1
  83. package/dist/constants/spacing.js +2 -1
  84. package/dist/design-system.json +154 -2
  85. package/dist/hooks/index.d.ts +12 -7
  86. package/dist/hooks/index.js +5 -0
  87. package/dist/hooks/useDimensions.d.ts +13 -8
  88. package/dist/hooks/useDimensions.js +123 -48
  89. package/dist/hooks/useFocusVisible.d.ts +30 -0
  90. package/dist/hooks/useFocusVisible.js +45 -0
  91. package/dist/hooks/useFontStyle.d.ts +2 -2
  92. package/dist/hooks/useFontStyle.js +3 -2
  93. package/dist/hooks/useHydrated.d.ts +13 -0
  94. package/dist/hooks/useHydrated.js +19 -0
  95. package/dist/hooks/useNotificationOffset.d.ts +20 -0
  96. package/dist/hooks/useNotificationOffset.js +34 -0
  97. package/dist/hooks/useResources.d.ts +21 -20
  98. package/dist/hooks/useResources.js +72 -68
  99. package/dist/hooks/useScalePress.d.ts +8 -5
  100. package/dist/hooks/useScalePress.js +16 -9
  101. package/dist/hooks/useShape.d.ts +24 -0
  102. package/dist/hooks/useShape.js +24 -0
  103. package/dist/hooks/useStaggeredEntrance.js +9 -7
  104. package/dist/hooks/useTheme.d.ts +3 -3
  105. package/dist/hooks/useTheme.js +177 -66
  106. package/dist/hooks/useWindowInsets.d.ts +13 -0
  107. package/dist/hooks/useWindowInsets.js +23 -0
  108. package/dist/index.d.ts +5 -5
  109. package/dist/lib/composeRefs.d.ts +8 -0
  110. package/dist/lib/composeRefs.js +20 -0
  111. package/dist/lib/haptics.d.ts +12 -0
  112. package/dist/lib/haptics.js +21 -0
  113. package/dist/lib/index.d.ts +6 -5
  114. package/dist/lib/index.js +1 -0
  115. package/dist/lib/interFonts.d.ts +15 -0
  116. package/dist/lib/interFonts.js +1 -0
  117. package/dist/lib/interFonts.native.d.ts +3 -0
  118. package/dist/lib/interFonts.native.js +20 -0
  119. package/dist/lib/popoverPlacement.d.ts +36 -0
  120. package/dist/lib/popoverPlacement.js +29 -0
  121. package/dist/lib/themedStyles.d.ts +1 -1
  122. package/dist/lib/useAnimatedValue.d.ts +15 -0
  123. package/dist/lib/useAnimatedValue.js +19 -0
  124. package/dist/lib/webHitTarget.d.ts +40 -0
  125. package/dist/lib/webHitTarget.js +37 -0
  126. package/dist/state/feedbackStore.d.ts +24 -0
  127. package/dist/state/feedbackStore.js +16 -0
  128. package/dist/state/globalUIStore.d.ts +27 -0
  129. package/dist/state/globalUIStore.js +23 -0
  130. package/dist/state/index.d.ts +7 -5
  131. package/dist/state/index.js +2 -0
  132. package/dist/state/initialScheme.d.ts +27 -0
  133. package/dist/state/initialScheme.js +29 -0
  134. package/dist/state/notify.d.ts +1 -1
  135. package/dist/state/themeColorScope.d.ts +1 -1
  136. package/dist/state/themeStore.d.ts +69 -16
  137. package/dist/state/themeStore.js +65 -38
  138. package/llms-full.md +56 -8
  139. package/llms.txt +10 -1
  140. package/package.json +69 -2
@@ -34,8 +34,39 @@ export type FontFamilyMap = Record<FontVariant, Record<FontFamilyWeight, string>
34
34
  * A per-variant override group. Partial per weight: missing weights fall back
35
35
  * to the group's own `regular` (not the package default), so an app that
36
36
  * registers only Regular + Medium never leaks a package face into its brand.
37
+ *
38
+ * `italic` maps weights to real italic faces. An italic weight that is missing
39
+ * falls back to the group's italic `regular`; a group with no `italic` map
40
+ * renders italic as `fontStyle: "italic"` on the upright face (the OS or
41
+ * browser synthesizes the slant).
42
+ */
43
+ export type FontFamilyOverride = Partial<Record<FontFamilyWeight, string>> & {
44
+ italic?: Partial<Record<FontFamilyWeight, string>>;
45
+ };
46
+ /**
47
+ * The package's serif. `"georgia"` (default) is the single system face on
48
+ * every platform; `"newsreader"` is a real serif family — four weights and a
49
+ * 400 italic — that `useResources({ serif: "newsreader" })` loads and turns on.
50
+ * Nothing about Newsreader ships to an app that keeps the default.
37
51
  */
38
- export type FontFamilyOverride = Partial<Record<FontFamilyWeight, string>>;
52
+ export type SerifPreset = "georgia" | "newsreader";
53
+ /**
54
+ * The Newsreader faces the `"newsreader"` preset resolves to. Native names
55
+ * match `@expo-google-fonts/newsreader`'s per-weight exports, which the app
56
+ * registers through `useResources({ serif: "newsreader", serifFonts })`; web
57
+ * is one stack the injected Google Fonts stylesheet serves, weight numeric.
58
+ */
59
+ export declare const newsreaderFamilies: {
60
+ readonly web: "\"Newsreader\", Georgia, 'Times New Roman', serif";
61
+ readonly native: {
62
+ light: string;
63
+ regular: string;
64
+ medium: string;
65
+ semibold: string;
66
+ bold: string;
67
+ };
68
+ readonly nativeItalic: "Newsreader_400Regular_Italic";
69
+ };
39
70
  /**
40
71
  * Font overrides a host app can inject to brand the package.
41
72
  *
@@ -65,6 +96,14 @@ export type ResolvedFontStyle = {
65
96
  fontFamily: string;
66
97
  /** Present only under the `"numeric"` weight strategy (web). */
67
98
  fontWeight?: "400" | "500" | "600" | "700";
99
+ /** Present only when italic was asked for and no italic face exists. */
100
+ fontStyle?: "italic";
101
+ };
102
+ export type FontStyleOptions = {
103
+ /** Render italic: a real italic face when one exists, else a synthesized slant. */
104
+ italic?: boolean;
105
+ /** The active serif preset (`useThemeStore().serifPreset`); defaults to Georgia. */
106
+ serifPreset?: SerifPreset;
68
107
  };
69
108
  /**
70
109
  * Resolve the `fontFamily` (+ optional numeric `fontWeight`) for a variant and
@@ -82,7 +121,7 @@ export type ResolvedFontStyle = {
82
121
  * own family per weight on web too, and must declare
83
122
  * `webWeightStrategy: "family"` to avoid a second synthesised layer of bold.
84
123
  */
85
- export declare function resolveFontStyle(overrides: FontOverrides, variant: FontVariant, weight: FontFamilyWeight): ResolvedFontStyle;
124
+ export declare function resolveFontStyle(overrides: FontOverrides, variant: FontVariant, weight: FontFamilyWeight, options?: FontStyleOptions): ResolvedFontStyle;
86
125
  /**
87
126
  * Typography scale — Tailwind-matching sizes for consistent text hierarchy.
88
127
  * Components can progressively adopt these tokens.
@@ -79,6 +79,23 @@ const sansSerifFamilies = isWebRuntime
79
79
  semibold: "sans-serif",
80
80
  bold: "sans-serif",
81
81
  };
82
+ /**
83
+ * The Newsreader faces the `"newsreader"` preset resolves to. Native names
84
+ * match `@expo-google-fonts/newsreader`'s per-weight exports, which the app
85
+ * registers through `useResources({ serif: "newsreader", serifFonts })`; web
86
+ * is one stack the injected Google Fonts stylesheet serves, weight numeric.
87
+ */
88
+ export const newsreaderFamilies = {
89
+ web: "\"Newsreader\", Georgia, 'Times New Roman', serif",
90
+ native: {
91
+ light: "Newsreader_400Regular",
92
+ regular: "Newsreader_400Regular",
93
+ medium: "Newsreader_500Medium",
94
+ semibold: "Newsreader_600SemiBold",
95
+ bold: "Newsreader_700Bold",
96
+ },
97
+ nativeItalic: "Newsreader_400Regular_Italic",
98
+ };
82
99
  /** The package's built-in families. Override per-app via `setFonts`. */
83
100
  export const fontFamilies = {
84
101
  serif: serifFamilies,
@@ -120,18 +137,40 @@ const WEB_FONT_WEIGHTS = {
120
137
  * own family per weight on web too, and must declare
121
138
  * `webWeightStrategy: "family"` to avoid a second synthesised layer of bold.
122
139
  */
123
- export function resolveFontStyle(overrides, variant, weight) {
124
- const defaults = fontFamilies[variant];
140
+ export function resolveFontStyle(overrides, variant, weight, options = {}) {
141
+ const { italic = false, serifPreset = "georgia" } = options;
142
+ const isWeb = Platform.OS === "web";
125
143
  const overrideGroup = overrides.families?.[variant];
126
- const fontFamily = overrideGroup
144
+ // Precedence for the upright face: app override → serif preset → package default.
145
+ const preset = variant === "serif" && serifPreset === "newsreader" && !overrideGroup;
146
+ const defaults = preset
147
+ ? isWeb
148
+ ? { light: newsreaderFamilies.web, regular: newsreaderFamilies.web, medium: newsreaderFamilies.web, semibold: newsreaderFamilies.web, bold: newsreaderFamilies.web }
149
+ : newsreaderFamilies.native
150
+ : fontFamilies[variant];
151
+ const upright = overrideGroup
127
152
  ? overrideGroup[weight] ?? overrideGroup.regular ?? defaults[weight]
128
153
  : defaults[weight];
129
- const strategy = Platform.OS === "web"
154
+ // A real italic face: the app's for this weight, else its italic regular,
155
+ // else the preset's native italic file. Web preset italics ride on
156
+ // `fontStyle` (the stylesheet serves the 400 italic under one family).
157
+ const italicFace = !italic
158
+ ? undefined
159
+ : overrideGroup?.italic
160
+ ? overrideGroup.italic[weight] ?? overrideGroup.italic.regular
161
+ : preset && !isWeb
162
+ ? newsreaderFamilies.nativeItalic
163
+ : undefined;
164
+ const fontFamily = italicFace ?? upright;
165
+ const synthesized = italic && italicFace === undefined;
166
+ const strategy = isWeb
130
167
  ? overrides.webWeightStrategy ?? defaultWebWeightStrategy
131
168
  : "family";
132
- return strategy === "numeric"
133
- ? { fontFamily, fontWeight: WEB_FONT_WEIGHTS[weight] }
134
- : { fontFamily };
169
+ return {
170
+ fontFamily,
171
+ ...(strategy === "numeric" && { fontWeight: WEB_FONT_WEIGHTS[weight] }),
172
+ ...(synthesized && { fontStyle: "italic" }),
173
+ };
135
174
  }
136
175
  export const typography = {
137
176
  xs: { fontSize: 12, lineHeight: 16 },
@@ -1,4 +1,5 @@
1
- export * from "./colors";
2
- export * from "./fonts";
3
- export * from "./motion";
4
- export * from "./spacing";
1
+ export * from "./colors.js";
2
+ export * from "./fonts.js";
3
+ export * from "./motion.js";
4
+ export * from "./spacing.js";
5
+ export * from "./interaction.js";
@@ -2,3 +2,4 @@ export * from "./colors.js";
2
2
  export * from "./fonts.js";
3
3
  export * from "./motion.js";
4
4
  export * from "./spacing.js";
5
+ export * from "./interaction.js";
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Interaction state tokens.
3
+ *
4
+ * One opacity for "pressed", one for "disabled", and the two press scales the
5
+ * kit's pressables share, so a Button, a pressable Card and a row read as the
6
+ * same system under the finger. Components layer these after their base
7
+ * styles; a caller `style` still wins.
8
+ */
9
+ export declare const interaction: {
10
+ /** Opacity of a filled surface while pressed. */
11
+ readonly pressedOpacity: 0.85;
12
+ /** Opacity of a disabled control and its label. */
13
+ readonly disabledOpacity: 0.5;
14
+ /** Press scale for large surfaces (Button, Card, Item). */
15
+ readonly pressedScale: 0.97;
16
+ /** Press scale for small controls (Switch, Checkbox, Toggle). */
17
+ readonly controlPressedScale: 0.92;
18
+ };
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Interaction state tokens.
3
+ *
4
+ * One opacity for "pressed", one for "disabled", and the two press scales the
5
+ * kit's pressables share, so a Button, a pressable Card and a row read as the
6
+ * same system under the finger. Components layer these after their base
7
+ * styles; a caller `style` still wins.
8
+ */
9
+ export const interaction = {
10
+ /** Opacity of a filled surface while pressed. */
11
+ pressedOpacity: 0.85,
12
+ /** Opacity of a disabled control and its label. */
13
+ disabledOpacity: 0.5,
14
+ /** Press scale for large surfaces (Button, Card, Item). */
15
+ pressedScale: 0.97,
16
+ /** Press scale for small controls (Switch, Checkbox, Toggle). */
17
+ controlPressedScale: 0.92,
18
+ };
@@ -30,6 +30,7 @@ export declare const spacing: {
30
30
  readonly cardPadding: 16;
31
31
  readonly dialogPadding: 20;
32
32
  readonly touchTarget: 44;
33
+ readonly minTarget: 24;
33
34
  readonly buttonPadding: 10;
34
35
  readonly inputPadding: 10;
35
36
  readonly listItemSpacing: 8;
@@ -47,5 +48,5 @@ export declare const spacing: {
47
48
  readonly iconLg: 32;
48
49
  readonly iconXl: 48;
49
50
  };
50
- export declare const base: 8, xxs: 2, xs: 4, sm: 8, smd: 12, md: 16, mdl: 20, lg: 24, xl: 32, xxl: 48, xxxl: 64, gutter: 16, gutterVertical: 24, screenPadding: 16, sectionSpacing: 24, rowPaddingY: 10, rowPaddingX: 16, rowGap: 12, rowMinHeight: 40, formRowMinHeight: 32, cardPadding: 16, dialogPadding: 20, touchTarget: 44, buttonPadding: 10, inputPadding: 10, listItemSpacing: 8, radiusNone: 0, radiusXs: 4, radiusSm: 8, radiusMd: 10, radiusLg: 14, radiusXl: 18, radius2xl: 24, radiusFull: 9999, iconXs: 12, iconSm: 16, iconMd: 24, iconLg: 32, iconXl: 48;
51
+ export declare const base: 8, xxs: 2, xs: 4, sm: 8, smd: 12, md: 16, mdl: 20, lg: 24, xl: 32, xxl: 48, xxxl: 64, gutter: 16, gutterVertical: 24, screenPadding: 16, sectionSpacing: 24, rowPaddingY: 10, rowPaddingX: 16, rowGap: 12, rowMinHeight: 40, formRowMinHeight: 32, cardPadding: 16, dialogPadding: 20, touchTarget: 44, minTarget: 24, buttonPadding: 10, inputPadding: 10, listItemSpacing: 8, radiusNone: 0, radiusXs: 4, radiusSm: 8, radiusMd: 10, radiusLg: 14, radiusXl: 18, radius2xl: 24, radiusFull: 9999, iconXs: 12, iconSm: 16, iconMd: 24, iconLg: 32, iconXl: 48;
51
52
  export declare const space: (multiplier: number) => number;
@@ -34,6 +34,7 @@ export const spacing = {
34
34
  cardPadding: 16, // Default card / stat card padding
35
35
  dialogPadding: 20, // Default dialog / alert dialog padding
36
36
  touchTarget: 44, // Minimum comfortable native touch target
37
+ minTarget: 24, // Smallest pointer target the kit draws on web (WCAG 2.5.8 minimum)
37
38
  // Component-specific
38
39
  buttonPadding: 10, // Default button padding
39
40
  inputPadding: 10, // Default input padding
@@ -55,6 +56,6 @@ export const spacing = {
55
56
  iconXl: 48,
56
57
  };
57
58
  // Export individual constants for convenience
58
- export const { base, xxs, xs, sm, smd, md, mdl, lg, xl, xxl, xxxl, gutter, gutterVertical, screenPadding, sectionSpacing, rowPaddingY, rowPaddingX, rowGap, rowMinHeight, formRowMinHeight, cardPadding, dialogPadding, touchTarget, buttonPadding, inputPadding, listItemSpacing, radiusNone, radiusXs, radiusSm, radiusMd, radiusLg, radiusXl, radius2xl, radiusFull, iconXs, iconSm, iconMd, iconLg, iconXl, } = spacing;
59
+ export const { base, xxs, xs, sm, smd, md, mdl, lg, xl, xxl, xxxl, gutter, gutterVertical, screenPadding, sectionSpacing, rowPaddingY, rowPaddingX, rowGap, rowMinHeight, formRowMinHeight, cardPadding, dialogPadding, touchTarget, minTarget, buttonPadding, inputPadding, listItemSpacing, radiusNone, radiusXs, radiusSm, radiusMd, radiusLg, radiusXl, radius2xl, radiusFull, iconXs, iconSm, iconMd, iconLg, iconXl, } = spacing;
59
60
  // Helper function to multiply base spacing
60
61
  export const space = (multiplier) => spacing.base * multiplier;
@@ -1,7 +1,7 @@
1
1
  {
2
- "schemaVersion": 1,
2
+ "schemaVersion": 2,
3
3
  "package": "@mrmeg/expo-ui",
4
- "version": "0.27.1",
4
+ "version": "0.28.0",
5
5
  "tokens": {
6
6
  "spacing": {
7
7
  "entries": [
@@ -97,6 +97,10 @@
97
97
  "name": "touchTarget",
98
98
  "value": 44
99
99
  },
100
+ {
101
+ "name": "minTarget",
102
+ "value": 24
103
+ },
100
104
  {
101
105
  "name": "buttonPadding",
102
106
  "value": 10
@@ -170,6 +174,50 @@
170
174
  "value": 48
171
175
  }
172
176
  ]
177
+ },
178
+ "typography": {
179
+ "entries": [
180
+ {
181
+ "name": "xs",
182
+ "value": 11,
183
+ "lineHeight": 16.5
184
+ },
185
+ {
186
+ "name": "sm",
187
+ "value": 12,
188
+ "lineHeight": 18
189
+ },
190
+ {
191
+ "name": "base",
192
+ "value": 14,
193
+ "lineHeight": 21
194
+ },
195
+ {
196
+ "name": "body",
197
+ "value": 15,
198
+ "lineHeight": 24.75
199
+ },
200
+ {
201
+ "name": "lg",
202
+ "value": 18,
203
+ "lineHeight": 27
204
+ },
205
+ {
206
+ "name": "xl",
207
+ "value": 22,
208
+ "lineHeight": 26.4
209
+ },
210
+ {
211
+ "name": "xxl",
212
+ "value": 28,
213
+ "lineHeight": 33.6
214
+ },
215
+ {
216
+ "name": "display",
217
+ "value": 34,
218
+ "lineHeight": 40.8
219
+ }
220
+ ]
173
221
  }
174
222
  },
175
223
  "palette": {
@@ -450,6 +498,86 @@
450
498
  "serif",
451
499
  "mono"
452
500
  ],
501
+ "fonts": {
502
+ "families": {
503
+ "serif": {
504
+ "light": [
505
+ "Georgia, 'Times New Roman', serif",
506
+ "Georgia"
507
+ ],
508
+ "regular": [
509
+ "Georgia, 'Times New Roman', serif",
510
+ "Georgia"
511
+ ],
512
+ "medium": [
513
+ "Georgia, 'Times New Roman', serif",
514
+ "Georgia"
515
+ ],
516
+ "semibold": [
517
+ "Georgia, 'Times New Roman', serif",
518
+ "Georgia"
519
+ ],
520
+ "bold": [
521
+ "Georgia, 'Times New Roman', serif",
522
+ "Georgia"
523
+ ]
524
+ },
525
+ "sansSerif": {
526
+ "light": [
527
+ "\"Inter\", system-ui, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"",
528
+ "Inter_400Regular",
529
+ "sans-serif"
530
+ ],
531
+ "regular": [
532
+ "\"Inter\", system-ui, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"",
533
+ "Inter_400Regular",
534
+ "sans-serif"
535
+ ],
536
+ "medium": [
537
+ "\"Inter\", system-ui, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"",
538
+ "Inter_500Medium",
539
+ "sans-serif"
540
+ ],
541
+ "semibold": [
542
+ "\"Inter\", system-ui, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"",
543
+ "Inter_600SemiBold",
544
+ "sans-serif"
545
+ ],
546
+ "bold": [
547
+ "\"Inter\", system-ui, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"",
548
+ "Inter_700Bold",
549
+ "sans-serif"
550
+ ]
551
+ },
552
+ "mono": {
553
+ "light": [
554
+ "ui-monospace, \"SF Mono\", Menlo, Consolas, \"Liberation Mono\", monospace",
555
+ "Menlo",
556
+ "monospace"
557
+ ],
558
+ "regular": [
559
+ "ui-monospace, \"SF Mono\", Menlo, Consolas, \"Liberation Mono\", monospace",
560
+ "Menlo",
561
+ "monospace"
562
+ ],
563
+ "medium": [
564
+ "ui-monospace, \"SF Mono\", Menlo, Consolas, \"Liberation Mono\", monospace",
565
+ "Menlo",
566
+ "monospace"
567
+ ],
568
+ "semibold": [
569
+ "ui-monospace, \"SF Mono\", Menlo, Consolas, \"Liberation Mono\", monospace",
570
+ "Menlo",
571
+ "monospace"
572
+ ],
573
+ "bold": [
574
+ "ui-monospace, \"SF Mono\", Menlo, Consolas, \"Liberation Mono\", monospace",
575
+ "Menlo",
576
+ "monospace"
577
+ ]
578
+ }
579
+ }
580
+ },
453
581
  "components": [
454
582
  {
455
583
  "name": "Accordion",
@@ -1297,6 +1425,14 @@
1297
1425
  "variantValues": null,
1298
1426
  "sizeValues": null
1299
1427
  },
1428
+ {
1429
+ "name": "Hydrated",
1430
+ "file": "Hydrated.tsx",
1431
+ "hasSize": false,
1432
+ "variantProp": null,
1433
+ "variantValues": null,
1434
+ "sizeValues": null
1435
+ },
1300
1436
  {
1301
1437
  "name": "Icon",
1302
1438
  "file": "Icon.tsx",
@@ -1321,6 +1457,14 @@
1321
1457
  "variantValues": null,
1322
1458
  "sizeValues": null
1323
1459
  },
1460
+ {
1461
+ "name": "ItemGroup",
1462
+ "file": "Item.tsx",
1463
+ "hasSize": false,
1464
+ "variantProp": null,
1465
+ "variantValues": null,
1466
+ "sizeValues": null
1467
+ },
1324
1468
  {
1325
1469
  "name": "ItemMedia",
1326
1470
  "file": "Item.tsx",
@@ -1404,6 +1548,14 @@
1404
1548
  "variantValues": null,
1405
1549
  "sizeValues": null
1406
1550
  },
1551
+ {
1552
+ "name": "Screen",
1553
+ "file": "Screen.tsx",
1554
+ "hasSize": false,
1555
+ "variantProp": null,
1556
+ "variantValues": null,
1557
+ "sizeValues": null
1558
+ },
1407
1559
  {
1408
1560
  "name": "Popover",
1409
1561
  "file": "Popover.tsx",
@@ -1,7 +1,12 @@
1
- export * from "./useDimensions";
2
- export * from "./useFontStyle";
3
- export * from "./useReduceMotion";
4
- export * from "./useResources";
5
- export * from "./useScalePress";
6
- export * from "./useStaggeredEntrance";
7
- export * from "./useTheme";
1
+ export * from "./useDimensions.js";
2
+ export * from "./useFocusVisible.js";
3
+ export * from "./useFontStyle.js";
4
+ export * from "./useReduceMotion.js";
5
+ export * from "./useResources.js";
6
+ export * from "./useScalePress.js";
7
+ export * from "./useShape.js";
8
+ export * from "./useStaggeredEntrance.js";
9
+ export * from "./useTheme.js";
10
+ export { useHydrated } from "./useHydrated.js";
11
+ export { useNotificationOffset } from "./useNotificationOffset.js";
12
+ export { useWindowInsets } from "./useWindowInsets.js";
@@ -1,7 +1,12 @@
1
1
  export * from "./useDimensions.js";
2
+ export * from "./useFocusVisible.js";
2
3
  export * from "./useFontStyle.js";
3
4
  export * from "./useReduceMotion.js";
4
5
  export * from "./useResources.js";
5
6
  export * from "./useScalePress.js";
7
+ export * from "./useShape.js";
6
8
  export * from "./useStaggeredEntrance.js";
7
9
  export * from "./useTheme.js";
10
+ export { useHydrated } from "./useHydrated.js";
11
+ export { useNotificationOffset } from "./useNotificationOffset.js";
12
+ export { useWindowInsets } from "./useWindowInsets.js";
@@ -4,7 +4,7 @@
4
4
  * 1. A desktop visitor sees no reflow — their real viewport lands in the
5
5
  * same breakpoint.
6
6
  * 2. A mobile visitor gets one frame of desktop-styled content before the
7
- * post-mount effect snaps to real dimensions — better than the inverse
7
+ * post-hydration update snaps to real dimensions — better than the inverse
8
8
  * (every desktop visitor seeing mobile-tiny, then snapping).
9
9
  * 3. It matches the frame the app hands `SafeAreaProvider`, and it is the
10
10
  * value the HTML shell `expo export` renders in Node is built from, so
@@ -29,13 +29,18 @@ type WindowDimensions = {
29
29
  * Provides a consistent way to access window dimensions and screen size
30
30
  * information across mobile and web.
31
31
  *
32
- * On web the first render can't read the window: server-side there is no DOM,
33
- * and reading it during the browser's first render would disagree with the
34
- * markup it hydrates. The width comes from `SsrViewportContext` when the host
35
- * provides a per-request value (server render + first client render must
36
- * provide the same one), falling back to `DEFAULT_VIEWPORT_WIDTH` / `_HEIGHT`.
37
- * A post-mount effect swaps in the real viewport and follows resize from
38
- * there.
32
+ * On web the server render and the browser's hydration pass can't read the
33
+ * window: server-side there is no DOM, and reading it while hydrating would
34
+ * disagree with the markup. Both use the width from `SsrViewportContext` when
35
+ * the host provides a per-request value (server render + first client render
36
+ * must provide the same one), falling back to `DEFAULT_VIEWPORT_WIDTH` /
37
+ * `_HEIGHT`. Right after hydration the real viewport takes over, and resize
38
+ * is followed from there. Every consumer shares one window listener and one
39
+ * snapshot, re-renders only when the width or height changes, and a component
40
+ * that mounts after hydration reads the current viewport straight away.
41
+ *
42
+ * The platform branch is chosen once, at module load (`Platform.OS` never
43
+ * changes at runtime), so each platform calls exactly one set of hooks.
39
44
  */
40
45
  export declare const useDimensions: () => WindowDimensions;
41
46
  export {};