@legendapp/list 3.0.0-beta.54 → 3.0.0-beta.55

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/animated.d.ts CHANGED
@@ -228,6 +228,13 @@ interface LegendListSpecificProps<ItemT, TItemType extends string | undefined> {
228
228
  * Style for the header component.
229
229
  */
230
230
  ListHeaderComponentStyle?: StyleProp<ViewStyle> | undefined;
231
+ /**
232
+ * Estimated height of the ListHeaderComponent. Provide this when the expected header height
233
+ * is known before layout so that only the items actually visible below the header are rendered
234
+ * on the initial frame, rather than a full screen's worth of items that are hidden behind it.
235
+ * The measured header size still replaces this value after layout.
236
+ */
237
+ estimatedHeaderSize?: number;
231
238
  /**
232
239
  * If true, auto-scrolls to end when new items are added.
233
240
  * Use an options object to opt into specific triggers and control whether that scroll is animated.
@@ -262,6 +269,12 @@ interface LegendListSpecificProps<ItemT, TItemType extends string | undefined> {
262
269
  * @default 1
263
270
  */
264
271
  numColumns?: number;
272
+ /**
273
+ * Force RTL mode for this list instance.
274
+ * When undefined, uses React Native's global I18nManager.isRTL.
275
+ * @default undefined
276
+ */
277
+ rtl?: boolean;
265
278
  /**
266
279
  * Called when scrolling reaches the end within onEndReachedThreshold.
267
280
  */
package/index.d.ts CHANGED
@@ -210,6 +210,7 @@ interface InternalState$1 {
210
210
  time: number;
211
211
  }>;
212
212
  scrollingTo?: InternalScrollTarget | undefined;
213
+ horizontalRTLScrollType?: "normal" | "inverted" | "negative";
213
214
  scrollLastCalculate?: number;
214
215
  scrollLength: number;
215
216
  scrollPending: number;
@@ -254,6 +255,7 @@ interface InternalState$1 {
254
255
  getFixedItemSize: LegendListPropsInternal["getFixedItemSize"];
255
256
  getItemType: LegendListPropsInternal["getItemType"];
256
257
  horizontal: boolean;
258
+ rtl?: boolean;
257
259
  initialContainerPoolRatio: number;
258
260
  itemsAreEqual: LegendListPropsInternal["itemsAreEqual"];
259
261
  keyExtractor: LegendListPropsInternal["keyExtractor"];
@@ -279,6 +281,8 @@ interface InternalState$1 {
279
281
  stickyIndicesArr: number[];
280
282
  stickyIndicesSet: Set<number>;
281
283
  stylePaddingBottom: number | undefined;
284
+ stylePaddingLeft: number | undefined;
285
+ stylePaddingRight: number | undefined;
282
286
  stylePaddingTop: number | undefined;
283
287
  useWindowScroll: boolean;
284
288
  };
@@ -552,6 +556,13 @@ interface LegendListSpecificProps<ItemT, TItemType extends string | undefined> {
552
556
  * Style for the header component.
553
557
  */
554
558
  ListHeaderComponentStyle?: StyleProp$1<ViewStyle$1> | undefined;
559
+ /**
560
+ * Estimated height of the ListHeaderComponent. Provide this when the expected header height
561
+ * is known before layout so that only the items actually visible below the header are rendered
562
+ * on the initial frame, rather than a full screen's worth of items that are hidden behind it.
563
+ * The measured header size still replaces this value after layout.
564
+ */
565
+ estimatedHeaderSize?: number;
555
566
  /**
556
567
  * If true, auto-scrolls to end when new items are added.
557
568
  * Use an options object to opt into specific triggers and control whether that scroll is animated.
@@ -586,6 +597,12 @@ interface LegendListSpecificProps<ItemT, TItemType extends string | undefined> {
586
597
  * @default 1
587
598
  */
588
599
  numColumns?: number;
600
+ /**
601
+ * Force RTL mode for this list instance.
602
+ * When undefined, uses React Native's global I18nManager.isRTL.
603
+ * @default undefined
604
+ */
605
+ rtl?: boolean;
589
606
  /**
590
607
  * Called when scrolling reaches the end within onEndReachedThreshold.
591
608
  */