@legendapp/list 3.0.0-beta.9 → 3.0.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 (48) hide show
  1. package/.DS_Store +0 -0
  2. package/CHANGELOG.md +21 -1
  3. package/README.md +8 -2
  4. package/animated.d.ts +659 -5
  5. package/animated.js +2 -2
  6. package/animated.mjs +1 -1
  7. package/keyboard-legacy.d.ts +226 -0
  8. package/keyboard-legacy.js +456 -0
  9. package/keyboard-legacy.mjs +435 -0
  10. package/keyboard.d.ts +261 -9
  11. package/keyboard.js +114 -135
  12. package/keyboard.mjs +115 -137
  13. package/package.json +55 -5
  14. package/{types-1Hgg1rTO.d.mts → react-native.d.ts} +269 -284
  15. package/react-native.js +6453 -0
  16. package/react-native.mjs +6424 -0
  17. package/{types-1Hgg1rTO.d.ts → react-native.web.d.ts} +330 -283
  18. package/react-native.web.js +7111 -0
  19. package/react-native.web.mjs +7082 -0
  20. package/react.d.ts +771 -0
  21. package/react.js +7111 -0
  22. package/react.mjs +7082 -0
  23. package/reanimated.d.ts +681 -8
  24. package/reanimated.js +225 -38
  25. package/reanimated.mjs +227 -40
  26. package/section-list.d.ts +663 -5
  27. package/section-list.js +39 -3829
  28. package/section-list.mjs +37 -3828
  29. package/animated.d.mts +0 -9
  30. package/index.d.mts +0 -23
  31. package/index.d.ts +0 -23
  32. package/index.js +0 -3935
  33. package/index.mjs +0 -3907
  34. package/index.native.d.mts +0 -23
  35. package/index.native.d.ts +0 -23
  36. package/index.native.js +0 -3739
  37. package/index.native.mjs +0 -3711
  38. package/keyboard-controller.d.mts +0 -12
  39. package/keyboard-controller.d.ts +0 -12
  40. package/keyboard-controller.js +0 -69
  41. package/keyboard-controller.mjs +0 -48
  42. package/keyboard.d.mts +0 -13
  43. package/reanimated.d.mts +0 -18
  44. package/section-list.d.mts +0 -113
  45. package/section-list.native.d.mts +0 -113
  46. package/section-list.native.d.ts +0 -113
  47. package/section-list.native.js +0 -3897
  48. package/section-list.native.mjs +0 -3876
package/.DS_Store CHANGED
Binary file
package/CHANGELOG.md CHANGED
@@ -1,7 +1,27 @@
1
- ## 3.0.0 beta
1
+ ## 3.0.0
2
2
 
3
3
  - Feat: Web support
4
4
  - Breaking: Some of the maintainVisibleContentPosition behavior for preventing jumping while scrolling is now core behavior, and the behavior for maintaining scroll position when adding data is controlled by the prop, which is now disabled by default.
5
+ - See https://legendapp.com/open-source/list/v3/migration/
6
+
7
+ ## 2.0.18
8
+ - Improvement: KeyboardAvoidingLegendList now supports KeyboardGestureArea with improved interactive behavior
9
+
10
+ ## 2.0.17
11
+ - Feat: Add stickyHeaderOffset property to control sticky header positioning
12
+ - Feat: Add sticky header backdrop component support
13
+ - Fix: Improve KeyboardAvoidingLegendList quality by using animated contentOffset y instead of reanimated scrollTo
14
+ - Fix: Initial scroll could sometimes be out of range beyond the ScrollView if some items are much larger than the estimated size
15
+ - Fix: Item layout updates now work correctly when container is the exact same size as previous item on old arch
16
+
17
+ ## 2.0.16
18
+ - Feat: Add KeyboardAvoidingLegendList component for better keyboard handling integration
19
+ - Fix: Stale containers are not being removed and overlap with new data when using getItemType #335
20
+ - Fix: Suppress keyExtractor warning when using lazy list mode #330
21
+
22
+ ## 2.0.15
23
+ - Fix: Container allocation for sticky headers could duplicate containers, causing rendering issues
24
+ - Fix: Sticky positioned components scrolling out of viewport after scrolling distance exceeded 5000
5
25
 
6
26
  ## 2.0.14
7
27
  - Feat: Add dataVersion prop to trigger re-render when mutating the data array in place
package/README.md CHANGED
@@ -26,7 +26,8 @@ Beyond standard `FlatList` capabilities:
26
26
  * `recycleItems`: (boolean) Toggles item component recycling.
27
27
  * `true`: Reuses item components for optimal performance. Be cautious if your item components contain local state, as it might be reused unexpectedly.
28
28
  * `false` (default): Creates new item components every time. Less performant but safer if items have complex internal state.
29
- * `maintainScrollAtEnd`: (boolean) If `true` and the user is scrolled near the bottom (within `maintainScrollAtEndThreshold * screen height`), the list automatically scrolls to the end when items are added or heights change. Useful for chat interfaces.
29
+ * `maintainScrollAtEnd`: Keeps the list pinned to the tail when the user is already near the end (within `maintainScrollAtEndThreshold * screen height`). Pass `true` for all triggers, or `{ animated?: boolean, on?: { dataChange?: boolean, layout?: boolean, itemLayout?: boolean } }`; if `on` is omitted, the object form also enables all triggers.
30
+ * `maintainVisibleContentPosition`: Keeps visible content steady during size/layout changes while scrolling up or when items resize above the viewport (default). Pass `true` or `{ data: true }` to also anchor during data updates; pass `false` to disable; pass `{ size: false }` to opt out of scroll-time stabilization.
30
31
  * `alignItemsAtEnd`: (boolean) Useful for chat UIs, content smaller than the View will be aligned to the bottom of the list.
31
32
 
32
33
  ---
@@ -54,11 +55,16 @@ npm install @legendapp/list
54
55
  yarn add @legendapp/list
55
56
  ```
56
57
 
58
+ ### Typed Imports
59
+
60
+ - React Native: `@legendapp/list/react-native`
61
+ - React: `@legendapp/list/react`
62
+
57
63
  ### Example
58
64
  ```tsx
59
65
  import React, { useRef } from "react"
60
66
  import { View, Image, Text, StyleSheet } from "react-native"
61
- import { LegendList, LegendListRef, LegendListRenderItemProps } from "@legendapp/list"
67
+ import { LegendList, LegendListRef, LegendListRenderItemProps } from "@legendapp/list/react-native"
62
68
 
63
69
  // Define the type for your data items
64
70
  interface UserData {