@legendapp/list 3.0.0-beta.33 → 3.0.0-beta.35
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 +12 -7
- package/index.d.ts +51 -12
- package/index.js +530 -247
- package/index.mjs +530 -247
- package/index.native.js +263 -149
- package/index.native.mjs +263 -149
- package/keyboard-controller.d.ts +12 -7
- package/keyboard.d.ts +7 -7
- package/keyboard.js +2 -1
- package/keyboard.mjs +3 -2
- package/package.json +9 -9
- package/{list-react-native.d.ts → react-native.d.ts} +45 -12
- package/{list-react-native.js → react-native.js} +263 -149
- package/{list-react-native.mjs → react-native.mjs} +263 -149
- package/{list-react.d.ts → react.d.ts} +87 -249
- package/{list-react.js → react.js} +530 -247
- package/{list-react.mjs → react.mjs} +530 -247
- package/reanimated.d.ts +17 -7
- package/reanimated.js +28 -5
- package/reanimated.mjs +28 -5
- package/section-list.d.ts +12 -7
|
@@ -1,19 +1,25 @@
|
|
|
1
1
|
import * as React$1 from 'react';
|
|
2
|
-
import { Key, ReactNode,
|
|
2
|
+
import { Key, ReactNode, ReactElement, HTMLAttributes, CSSProperties, Ref, RefAttributes, Dispatch, SetStateAction } from 'react';
|
|
3
|
+
|
|
4
|
+
type ScrollEventTarget = Window | HTMLElement;
|
|
3
5
|
|
|
4
6
|
interface ScrollViewMethods {
|
|
5
|
-
scrollBy(x: number, y: number): void;
|
|
6
7
|
getBoundingClientRect(): DOMRect | null | undefined;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
getContentNode(): HTMLElement | null;
|
|
9
|
+
getCurrentScrollOffset(): number;
|
|
10
|
+
getScrollableNode(): HTMLElement;
|
|
11
|
+
getScrollEventTarget(): ScrollEventTarget | null;
|
|
10
12
|
getScrollResponder(): HTMLElement | null;
|
|
11
|
-
|
|
13
|
+
isWindowScroll?(): boolean;
|
|
14
|
+
scrollBy(x: number, y: number): void;
|
|
12
15
|
scrollTo(options: {
|
|
13
16
|
x?: number;
|
|
14
17
|
y?: number;
|
|
15
18
|
animated?: boolean;
|
|
16
19
|
}): void;
|
|
20
|
+
scrollToEnd(options?: {
|
|
21
|
+
animated?: boolean;
|
|
22
|
+
}): void;
|
|
17
23
|
scrollToOffset(params: {
|
|
18
24
|
offset: number;
|
|
19
25
|
animated?: boolean;
|
|
@@ -22,11 +28,6 @@ interface ScrollViewMethods {
|
|
|
22
28
|
|
|
23
29
|
type AnimatedValue = number;
|
|
24
30
|
|
|
25
|
-
type LooseMeasureCallback = (x: number, y: number, width: number, height: number, pageX: number, pageY: number) => void;
|
|
26
|
-
interface LooseView {
|
|
27
|
-
measure?: (callback: LooseMeasureCallback) => void;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
31
|
type ListenerType = "activeStickyIndex" | "debugComputedScroll" | "debugRawScroll" | "extraData" | "footerSize" | "headerSize" | "lastItemKeys" | "lastPositionUpdate" | "maintainVisibleContentPosition" | "numColumns" | "numContainers" | "numContainersPooled" | "otherAxisSize" | "readyToRender" | "scrollAdjust" | "scrollAdjustPending" | "scrollAdjustUserOffset" | "scrollSize" | "snapToOffsets" | "stylePaddingTop" | "totalSize" | `containerColumn${number}` | `containerSpan${number}` | `containerItemData${number}` | `containerItemKey${number}` | `containerPosition${number}` | `containerSticky${number}`;
|
|
31
32
|
type LegendListListenerType = Extract<ListenerType, "activeStickyIndex" | "footerSize" | "headerSize" | "lastItemKeys" | "lastPositionUpdate" | "numContainers" | "numContainersPooled" | "otherAxisSize" | "readyToRender" | "snapToOffsets" | "totalSize">;
|
|
32
33
|
type ListenerTypeValueMap = {
|
|
@@ -107,19 +108,19 @@ type StylesAsSharedValue<Style> = {
|
|
|
107
108
|
[key in keyof Style]: Style[key] | BaseSharedValue<Style[key]>;
|
|
108
109
|
};
|
|
109
110
|
|
|
110
|
-
interface Insets
|
|
111
|
+
interface Insets {
|
|
111
112
|
top: number;
|
|
112
113
|
left: number;
|
|
113
114
|
bottom: number;
|
|
114
115
|
right: number;
|
|
115
116
|
}
|
|
116
|
-
interface LayoutRectangle
|
|
117
|
+
interface LayoutRectangle {
|
|
117
118
|
x: number;
|
|
118
119
|
y: number;
|
|
119
120
|
width: number;
|
|
120
121
|
height: number;
|
|
121
122
|
}
|
|
122
|
-
interface NativeScrollEvent
|
|
123
|
+
interface NativeScrollEvent {
|
|
123
124
|
contentOffset: {
|
|
124
125
|
x: number;
|
|
125
126
|
y: number;
|
|
@@ -132,14 +133,37 @@ interface NativeScrollEvent$1 {
|
|
|
132
133
|
width: number;
|
|
133
134
|
height: number;
|
|
134
135
|
};
|
|
135
|
-
contentInset: Insets
|
|
136
|
+
contentInset: Insets;
|
|
136
137
|
zoomScale: number;
|
|
137
138
|
}
|
|
138
|
-
interface NativeSyntheticEvent
|
|
139
|
+
interface NativeSyntheticEvent<T> {
|
|
139
140
|
nativeEvent: T;
|
|
140
141
|
}
|
|
141
|
-
type ViewStyle
|
|
142
|
-
type StyleProp
|
|
142
|
+
type ViewStyle = Record<string, unknown>;
|
|
143
|
+
type StyleProp<T> = T | T[] | null | undefined | false;
|
|
144
|
+
interface ScrollEventTargetLike {
|
|
145
|
+
addEventListener(type: string, listener: (...args: any[]) => void): void;
|
|
146
|
+
removeEventListener(type: string, listener: (...args: any[]) => void): void;
|
|
147
|
+
}
|
|
148
|
+
interface ScrollableNodeLike {
|
|
149
|
+
scrollLeft?: number;
|
|
150
|
+
scrollTop?: number;
|
|
151
|
+
}
|
|
152
|
+
interface LegendListScrollerRef {
|
|
153
|
+
flashScrollIndicators(): void;
|
|
154
|
+
getCurrentScrollOffset?(): number;
|
|
155
|
+
getScrollEventTarget(): ScrollEventTargetLike | null;
|
|
156
|
+
getScrollableNode(): ScrollableNodeLike | null;
|
|
157
|
+
getScrollResponder(): unknown;
|
|
158
|
+
scrollTo(options: {
|
|
159
|
+
animated?: boolean;
|
|
160
|
+
x?: number;
|
|
161
|
+
y?: number;
|
|
162
|
+
}): void;
|
|
163
|
+
scrollToEnd(options?: {
|
|
164
|
+
animated?: boolean;
|
|
165
|
+
}): void;
|
|
166
|
+
}
|
|
143
167
|
type BaseScrollViewProps<TScrollView> = Omit<TScrollView, "contentOffset" | "maintainVisibleContentPosition" | "stickyHeaderIndices" | "removeClippedSubviews" | "children" | "onScroll">;
|
|
144
168
|
interface DataModeProps<ItemT, TItemType extends string | undefined> {
|
|
145
169
|
/**
|
|
@@ -268,7 +292,7 @@ interface LegendListSpecificProps<ItemT, TItemType extends string | undefined> {
|
|
|
268
292
|
/**
|
|
269
293
|
* Style for the footer component.
|
|
270
294
|
*/
|
|
271
|
-
ListFooterComponentStyle?: StyleProp
|
|
295
|
+
ListFooterComponentStyle?: StyleProp<ViewStyle> | undefined;
|
|
272
296
|
/**
|
|
273
297
|
* Component or element to render above the list.
|
|
274
298
|
*/
|
|
@@ -276,7 +300,7 @@ interface LegendListSpecificProps<ItemT, TItemType extends string | undefined> {
|
|
|
276
300
|
/**
|
|
277
301
|
* Style for the header component.
|
|
278
302
|
*/
|
|
279
|
-
ListHeaderComponentStyle?: StyleProp
|
|
303
|
+
ListHeaderComponentStyle?: StyleProp<ViewStyle> | undefined;
|
|
280
304
|
/**
|
|
281
305
|
* If true, auto-scrolls to end when new items are added.
|
|
282
306
|
* @default false
|
|
@@ -296,6 +320,11 @@ interface LegendListSpecificProps<ItemT, TItemType extends string | undefined> {
|
|
|
296
320
|
* - true enables both behaviors; false disables both.
|
|
297
321
|
*/
|
|
298
322
|
maintainVisibleContentPosition?: boolean | MaintainVisibleContentPositionConfig<ItemT>;
|
|
323
|
+
/**
|
|
324
|
+
* Web only: when true, listens to window/body scrolling instead of rendering a scrollable list container.
|
|
325
|
+
* @default false
|
|
326
|
+
*/
|
|
327
|
+
useWindowScroll?: boolean;
|
|
299
328
|
/**
|
|
300
329
|
* Number of columns to render items in.
|
|
301
330
|
* @default 1
|
|
@@ -330,7 +359,7 @@ interface LegendListSpecificProps<ItemT, TItemType extends string | undefined> {
|
|
|
330
359
|
* Function to call when the user pulls to refresh.
|
|
331
360
|
*/
|
|
332
361
|
onRefresh?: () => void;
|
|
333
|
-
onScroll?: (event: NativeSyntheticEvent
|
|
362
|
+
onScroll?: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
|
|
334
363
|
/**
|
|
335
364
|
* Called when scrolling reaches the start within onStartReachedThreshold.
|
|
336
365
|
*/
|
|
@@ -490,10 +519,11 @@ interface InternalState {
|
|
|
490
519
|
num: number;
|
|
491
520
|
avg: number;
|
|
492
521
|
}>;
|
|
493
|
-
columns:
|
|
494
|
-
columnSpans:
|
|
522
|
+
columns: Array<number | undefined>;
|
|
523
|
+
columnSpans: Array<number | undefined>;
|
|
495
524
|
containerItemKeys: Map<string, number>;
|
|
496
525
|
containerItemTypes: Map<number, string>;
|
|
526
|
+
dataChangeEpoch: number;
|
|
497
527
|
dataChangeNeedsScrollUpdate: boolean;
|
|
498
528
|
didColumnsChange?: boolean;
|
|
499
529
|
didDataChange?: boolean;
|
|
@@ -522,7 +552,7 @@ interface InternalState {
|
|
|
522
552
|
isFirst?: boolean;
|
|
523
553
|
isStartReached: boolean | null;
|
|
524
554
|
lastBatchingAction: number;
|
|
525
|
-
lastLayout: LayoutRectangle
|
|
555
|
+
lastLayout: LayoutRectangle | undefined;
|
|
526
556
|
lastScrollAdjustForHistory?: number;
|
|
527
557
|
lastScrollDelta: number;
|
|
528
558
|
loadStartTime: number;
|
|
@@ -534,18 +564,19 @@ interface InternalState {
|
|
|
534
564
|
quietPasses: number;
|
|
535
565
|
expiresAt: number;
|
|
536
566
|
};
|
|
537
|
-
contentInsetOverride?: Partial<Insets
|
|
538
|
-
nativeContentInset?: Insets
|
|
567
|
+
contentInsetOverride?: Partial<Insets> | null;
|
|
568
|
+
nativeContentInset?: Insets;
|
|
539
569
|
nativeMarginTop: number;
|
|
540
570
|
needsOtherAxisSize?: boolean;
|
|
541
571
|
otherAxisSize?: number;
|
|
542
572
|
pendingTotalSize?: number;
|
|
543
|
-
|
|
573
|
+
pendingScrollResolve?: (() => void) | undefined;
|
|
574
|
+
positions: Array<number | undefined>;
|
|
544
575
|
previousData?: readonly unknown[];
|
|
545
576
|
queuedCalculateItemsInView: number | undefined;
|
|
546
577
|
queuedMVCPRecalculate?: number;
|
|
547
578
|
queuedInitialLayout?: boolean | undefined;
|
|
548
|
-
refScroller: React.RefObject<
|
|
579
|
+
refScroller: React.RefObject<LegendListScrollerRef | null>;
|
|
549
580
|
scroll: number;
|
|
550
581
|
scrollAdjustHandler: ScrollAdjustHandler;
|
|
551
582
|
scrollForNextCalculateItemsInView: {
|
|
@@ -569,6 +600,7 @@ interface InternalState {
|
|
|
569
600
|
startBuffered: number;
|
|
570
601
|
startBufferedId?: string;
|
|
571
602
|
startNoBuffer: number;
|
|
603
|
+
startReachedSnapshotDataChangeEpoch: number | undefined;
|
|
572
604
|
startReachedSnapshot: ThresholdSnapshot | undefined;
|
|
573
605
|
stickyContainerPool: Set<number>;
|
|
574
606
|
stickyContainers: Map<number, number>;
|
|
@@ -589,7 +621,7 @@ interface InternalState {
|
|
|
589
621
|
alwaysRender: AlwaysRenderConfig | undefined;
|
|
590
622
|
alwaysRenderIndicesArr: number[];
|
|
591
623
|
alwaysRenderIndicesSet: Set<number>;
|
|
592
|
-
contentInset: Insets
|
|
624
|
+
contentInset: Insets | undefined;
|
|
593
625
|
data: readonly any[];
|
|
594
626
|
dataVersion: Key | undefined;
|
|
595
627
|
drawDistance: number;
|
|
@@ -618,12 +650,14 @@ interface InternalState {
|
|
|
618
650
|
renderItem: LegendListPropsInternal["renderItem"];
|
|
619
651
|
scrollBuffer?: number;
|
|
620
652
|
snapToIndices: number[] | undefined;
|
|
653
|
+
positionComponentInternal: React.ComponentType<any> | undefined;
|
|
621
654
|
stickyPositionComponentInternal: React.ComponentType<any> | undefined;
|
|
622
655
|
stickyIndicesArr: number[];
|
|
623
656
|
stickyIndicesSet: Set<number>;
|
|
624
657
|
stylePaddingBottom: number | undefined;
|
|
625
658
|
stylePaddingTop: number | undefined;
|
|
626
659
|
suggestEstimatedItemSize: boolean;
|
|
660
|
+
useWindowScroll: boolean;
|
|
627
661
|
};
|
|
628
662
|
}
|
|
629
663
|
interface ViewableRange<T> {
|
|
@@ -652,7 +686,7 @@ type LegendListState$1 = {
|
|
|
652
686
|
listen: <T extends LegendListListenerType>(listenerType: T, callback: (value: ListenerTypeValueMap[T]) => void) => () => void;
|
|
653
687
|
listenToPosition: (key: string, callback: (value: number) => void) => () => void;
|
|
654
688
|
positionAtIndex: (index: number) => number;
|
|
655
|
-
|
|
689
|
+
positionByKey: (key: string) => number | undefined;
|
|
656
690
|
scroll: number;
|
|
657
691
|
scrollLength: number;
|
|
658
692
|
scrollVelocity: number;
|
|
@@ -691,7 +725,7 @@ type LegendListRef$1 = {
|
|
|
691
725
|
scrollIndexIntoView(params: {
|
|
692
726
|
animated?: boolean | undefined;
|
|
693
727
|
index: number;
|
|
694
|
-
}): void
|
|
728
|
+
}): Promise<void>;
|
|
695
729
|
/**
|
|
696
730
|
* Scrolls a specific index into view.
|
|
697
731
|
* @param params - Parameters for scrolling.
|
|
@@ -701,7 +735,7 @@ type LegendListRef$1 = {
|
|
|
701
735
|
scrollItemIntoView(params: {
|
|
702
736
|
animated?: boolean | undefined;
|
|
703
737
|
item: any;
|
|
704
|
-
}): void
|
|
738
|
+
}): Promise<void>;
|
|
705
739
|
/**
|
|
706
740
|
* Scrolls to the end of the list.
|
|
707
741
|
* @param options - Options for scrolling.
|
|
@@ -711,7 +745,7 @@ type LegendListRef$1 = {
|
|
|
711
745
|
scrollToEnd(options?: {
|
|
712
746
|
animated?: boolean | undefined;
|
|
713
747
|
viewOffset?: number | undefined;
|
|
714
|
-
}): void
|
|
748
|
+
}): Promise<void>;
|
|
715
749
|
/**
|
|
716
750
|
* Scrolls to a specific index in the list.
|
|
717
751
|
* @param params - Parameters for scrolling.
|
|
@@ -725,7 +759,7 @@ type LegendListRef$1 = {
|
|
|
725
759
|
index: number;
|
|
726
760
|
viewOffset?: number | undefined;
|
|
727
761
|
viewPosition?: number | undefined;
|
|
728
|
-
}): void
|
|
762
|
+
}): Promise<void>;
|
|
729
763
|
/**
|
|
730
764
|
* Scrolls to a specific item in the list.
|
|
731
765
|
* @param params - Parameters for scrolling.
|
|
@@ -739,7 +773,7 @@ type LegendListRef$1 = {
|
|
|
739
773
|
item: any;
|
|
740
774
|
viewOffset?: number | undefined;
|
|
741
775
|
viewPosition?: number | undefined;
|
|
742
|
-
}): void
|
|
776
|
+
}): Promise<void>;
|
|
743
777
|
/**
|
|
744
778
|
* Scrolls to a specific offset in pixels.
|
|
745
779
|
* @param params - Parameters for scrolling.
|
|
@@ -749,7 +783,7 @@ type LegendListRef$1 = {
|
|
|
749
783
|
scrollToOffset(params: {
|
|
750
784
|
offset: number;
|
|
751
785
|
animated?: boolean | undefined;
|
|
752
|
-
}): void
|
|
786
|
+
}): Promise<void>;
|
|
753
787
|
/**
|
|
754
788
|
* Sets or adds to the offset of the visible content anchor.
|
|
755
789
|
* @param value - The offset to set or add.
|
|
@@ -773,7 +807,7 @@ type LegendListRef$1 = {
|
|
|
773
807
|
* Reports an externally measured content inset. Pass null/undefined to clear.
|
|
774
808
|
* Values are merged on top of props/animated/native insets.
|
|
775
809
|
*/
|
|
776
|
-
reportContentInset(inset?: Partial<Insets
|
|
810
|
+
reportContentInset(inset?: Partial<Insets> | null): void;
|
|
777
811
|
};
|
|
778
812
|
interface ViewToken<ItemT = any> {
|
|
779
813
|
containerId: number;
|
|
@@ -864,244 +898,48 @@ type GetRenderedItemResult<ItemT> = {
|
|
|
864
898
|
};
|
|
865
899
|
type GetRenderedItem = (key: string) => GetRenderedItemResult<any> | null;
|
|
866
900
|
|
|
867
|
-
|
|
868
|
-
type Insets = Insets$1;
|
|
869
|
-
/** @deprecated Use `@legendapp/list/react-native` or `@legendapp/list/react` for strict typing */
|
|
870
|
-
type LayoutRectangle = LayoutRectangle$1;
|
|
871
|
-
/** @deprecated Use `@legendapp/list/react-native` or `@legendapp/list/react` for strict typing */
|
|
872
|
-
type NativeScrollEvent = NativeScrollEvent$1;
|
|
873
|
-
/** @deprecated Use `@legendapp/list/react-native` or `@legendapp/list/react` for strict typing */
|
|
874
|
-
type NativeSyntheticEvent<T> = NativeSyntheticEvent$1<T>;
|
|
875
|
-
/** @deprecated Use `@legendapp/list/react-native` or `@legendapp/list/react` for strict typing */
|
|
876
|
-
type ViewStyle = ViewStyle$1;
|
|
877
|
-
/** @deprecated Use `@legendapp/list/react-native` or `@legendapp/list/react` for strict typing */
|
|
878
|
-
type StyleProp<T> = StyleProp$1<T>;
|
|
879
|
-
interface LooseAccessibilityActionEvent {
|
|
880
|
-
nativeEvent?: {
|
|
881
|
-
actionName?: string;
|
|
882
|
-
};
|
|
883
|
-
}
|
|
884
|
-
type AccessibilityActionEvent = LooseAccessibilityActionEvent;
|
|
885
|
-
type LooseAccessibilityRole = string;
|
|
886
|
-
type AccessibilityRole = LooseAccessibilityRole;
|
|
887
|
-
interface LooseAccessibilityState {
|
|
888
|
-
busy?: boolean;
|
|
889
|
-
checked?: boolean | "mixed";
|
|
890
|
-
disabled?: boolean;
|
|
891
|
-
expanded?: boolean;
|
|
892
|
-
selected?: boolean;
|
|
893
|
-
}
|
|
894
|
-
type AccessibilityState = LooseAccessibilityState;
|
|
895
|
-
interface LooseAccessibilityValue {
|
|
896
|
-
max?: number;
|
|
897
|
-
min?: number;
|
|
898
|
-
now?: number;
|
|
899
|
-
text?: string;
|
|
900
|
-
}
|
|
901
|
-
type AccessibilityValue = LooseAccessibilityValue;
|
|
902
|
-
type LooseColorValue = string | number;
|
|
903
|
-
type ColorValue = LooseColorValue;
|
|
904
|
-
interface LooseGestureResponderEvent {
|
|
905
|
-
nativeEvent?: unknown;
|
|
906
|
-
}
|
|
907
|
-
type GestureResponderEvent = LooseGestureResponderEvent;
|
|
908
|
-
interface LoosePointerEvent {
|
|
909
|
-
nativeEvent?: unknown;
|
|
910
|
-
}
|
|
911
|
-
type PointerEvent = LoosePointerEvent;
|
|
912
|
-
interface LooseRefreshControlProps {
|
|
913
|
-
onRefresh?: () => void;
|
|
914
|
-
progressViewOffset?: number;
|
|
915
|
-
refreshing?: boolean;
|
|
916
|
-
}
|
|
917
|
-
type RefreshControlProps = LooseRefreshControlProps;
|
|
918
|
-
type LooseRole = string;
|
|
919
|
-
type Role = LooseRole;
|
|
920
|
-
interface PointProp {
|
|
921
|
-
x: number;
|
|
922
|
-
y: number;
|
|
923
|
-
}
|
|
924
|
-
interface LayoutChangeEvent {
|
|
901
|
+
type LooseLayoutChangeEvent = {
|
|
925
902
|
nativeEvent: {
|
|
926
903
|
layout: LayoutRectangle;
|
|
927
904
|
};
|
|
905
|
+
};
|
|
906
|
+
type LooseMeasureCallback = (x: number, y: number, width: number, height: number, pageX: number, pageY: number) => void;
|
|
907
|
+
interface LooseView {
|
|
908
|
+
measure?: (callback: LooseMeasureCallback) => void;
|
|
928
909
|
}
|
|
929
|
-
/** @deprecated Use `@legendapp/list/react-native` or `@legendapp/list/react` for strict typing */
|
|
930
910
|
interface LooseScrollViewProps {
|
|
931
|
-
|
|
932
|
-
accessibilityActions?: Array<{
|
|
933
|
-
label?: string;
|
|
934
|
-
name: string;
|
|
935
|
-
}>;
|
|
936
|
-
accessibilityElementsHidden?: boolean;
|
|
937
|
-
accessibilityHint?: string;
|
|
938
|
-
accessibilityIgnoresInvertColors?: boolean;
|
|
939
|
-
accessibilityLabel?: string;
|
|
940
|
-
accessibilityLabelledBy?: string | string[];
|
|
941
|
-
accessibilityLanguage?: string;
|
|
942
|
-
accessibilityLargeContentTitle?: string;
|
|
943
|
-
accessibilityLiveRegion?: "none" | "polite" | "assertive";
|
|
944
|
-
accessibilityRespondsToUserInteraction?: boolean;
|
|
945
|
-
accessibilityRole?: AccessibilityRole;
|
|
946
|
-
accessibilityShowsLargeContentViewer?: boolean;
|
|
947
|
-
accessibilityState?: AccessibilityState;
|
|
948
|
-
accessibilityValue?: AccessibilityValue;
|
|
949
|
-
accessibilityViewIsModal?: boolean;
|
|
950
|
-
accessible?: boolean;
|
|
951
|
-
alwaysBounceHorizontal?: boolean;
|
|
952
|
-
alwaysBounceVertical?: boolean;
|
|
953
|
-
"aria-busy"?: boolean;
|
|
954
|
-
"aria-checked"?: boolean | "mixed";
|
|
955
|
-
"aria-disabled"?: boolean;
|
|
956
|
-
"aria-expanded"?: boolean;
|
|
957
|
-
"aria-hidden"?: boolean;
|
|
958
|
-
"aria-label"?: string;
|
|
959
|
-
"aria-labelledby"?: string;
|
|
960
|
-
"aria-live"?: "polite" | "assertive" | "off";
|
|
961
|
-
"aria-modal"?: boolean;
|
|
962
|
-
"aria-selected"?: boolean;
|
|
963
|
-
"aria-valuemax"?: number;
|
|
964
|
-
"aria-valuemin"?: number;
|
|
965
|
-
"aria-valuenow"?: number;
|
|
966
|
-
"aria-valuetext"?: string;
|
|
967
|
-
automaticallyAdjustContentInsets?: boolean;
|
|
968
|
-
automaticallyAdjustKeyboardInsets?: boolean;
|
|
969
|
-
automaticallyAdjustsScrollIndicatorInsets?: boolean;
|
|
970
|
-
bounces?: boolean;
|
|
971
|
-
bouncesZoom?: boolean;
|
|
972
|
-
canCancelContentTouches?: boolean;
|
|
973
|
-
centerContent?: boolean;
|
|
974
|
-
children?: ReactNode;
|
|
975
|
-
collapsable?: boolean;
|
|
976
|
-
collapsableChildren?: boolean;
|
|
977
|
-
contentContainerStyle?: StyleProp<ViewStyle> | CSSProperties;
|
|
911
|
+
contentContainerStyle?: StyleProp<ViewStyle>;
|
|
978
912
|
contentInset?: Insets;
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
directionalLockEnabled?: boolean;
|
|
983
|
-
disableIntervalMomentum?: boolean;
|
|
984
|
-
disableScrollViewPanResponder?: boolean;
|
|
985
|
-
endFillColor?: ColorValue;
|
|
986
|
-
fadingEdgeLength?: number | {
|
|
987
|
-
end?: number;
|
|
988
|
-
start?: number;
|
|
913
|
+
contentOffset?: {
|
|
914
|
+
x: number;
|
|
915
|
+
y: number;
|
|
989
916
|
};
|
|
990
|
-
focusable?: boolean;
|
|
991
|
-
hasTVPreferredFocus?: boolean;
|
|
992
|
-
hitSlop?: number | Insets;
|
|
993
917
|
horizontal?: boolean;
|
|
994
|
-
id?: string;
|
|
995
|
-
importantForAccessibility?: "auto" | "yes" | "no" | "no-hide-descendants";
|
|
996
|
-
indicatorStyle?: "default" | "black" | "white";
|
|
997
|
-
innerViewRef?: Ref<unknown>;
|
|
998
|
-
invertStickyHeaders?: boolean;
|
|
999
|
-
isTVSelectable?: boolean;
|
|
1000
|
-
keyboardDismissMode?: "none" | "interactive" | "on-drag";
|
|
1001
|
-
keyboardShouldPersistTaps?: boolean | "always" | "never" | "handled";
|
|
1002
918
|
maintainVisibleContentPosition?: {
|
|
1003
919
|
autoscrollToTopThreshold?: number;
|
|
1004
920
|
minIndexForVisible: number;
|
|
1005
921
|
};
|
|
1006
|
-
|
|
1007
|
-
minimumZoomScale?: number;
|
|
1008
|
-
nativeID?: string;
|
|
1009
|
-
needsOffscreenAlphaCompositing?: boolean;
|
|
1010
|
-
nestedScrollEnabled?: boolean;
|
|
1011
|
-
onAccessibilityAction?: (event: AccessibilityActionEvent) => void;
|
|
1012
|
-
onAccessibilityEscape?: () => void;
|
|
1013
|
-
onAccessibilityTap?: () => void;
|
|
1014
|
-
onBlur?: (event: unknown) => void;
|
|
1015
|
-
onContentSizeChange?: (width: number, height: number) => void;
|
|
1016
|
-
onFocus?: (event: unknown) => void;
|
|
1017
|
-
onLayout?: (event: LayoutChangeEvent) => void;
|
|
1018
|
-
onMagicTap?: () => void;
|
|
922
|
+
onLayout?: (event: LooseLayoutChangeEvent) => void;
|
|
1019
923
|
onMomentumScrollBegin?: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
|
|
1020
924
|
onMomentumScrollEnd?: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
|
|
1021
|
-
onMoveShouldSetResponder?: (event: GestureResponderEvent) => boolean;
|
|
1022
|
-
onMoveShouldSetResponderCapture?: (event: GestureResponderEvent) => boolean;
|
|
1023
|
-
onPointerCancel?: (event: PointerEvent) => void;
|
|
1024
|
-
onPointerCancelCapture?: (event: PointerEvent) => void;
|
|
1025
|
-
onPointerDown?: (event: PointerEvent) => void;
|
|
1026
|
-
onPointerDownCapture?: (event: PointerEvent) => void;
|
|
1027
|
-
onPointerEnter?: (event: PointerEvent) => void;
|
|
1028
|
-
onPointerEnterCapture?: (event: PointerEvent) => void;
|
|
1029
|
-
onPointerLeave?: (event: PointerEvent) => void;
|
|
1030
|
-
onPointerLeaveCapture?: (event: PointerEvent) => void;
|
|
1031
|
-
onPointerMove?: (event: PointerEvent) => void;
|
|
1032
|
-
onPointerMoveCapture?: (event: PointerEvent) => void;
|
|
1033
|
-
onPointerUp?: (event: PointerEvent) => void;
|
|
1034
|
-
onPointerUpCapture?: (event: PointerEvent) => void;
|
|
1035
|
-
onResponderEnd?: (event: GestureResponderEvent) => void;
|
|
1036
|
-
onResponderGrant?: (event: GestureResponderEvent) => void;
|
|
1037
|
-
onResponderMove?: (event: GestureResponderEvent) => void;
|
|
1038
|
-
onResponderReject?: (event: GestureResponderEvent) => void;
|
|
1039
|
-
onResponderRelease?: (event: GestureResponderEvent) => void;
|
|
1040
|
-
onResponderStart?: (event: GestureResponderEvent) => void;
|
|
1041
|
-
onResponderTerminate?: (event: GestureResponderEvent) => void;
|
|
1042
|
-
onResponderTerminationRequest?: (event: GestureResponderEvent) => boolean;
|
|
1043
925
|
onScroll?: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
|
|
1044
|
-
|
|
1045
|
-
onScrollBeginDrag?: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
|
|
1046
|
-
onScrollEndDrag?: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
|
|
1047
|
-
onScrollToTop?: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
|
|
1048
|
-
onStartShouldSetResponder?: (event: GestureResponderEvent) => boolean;
|
|
1049
|
-
onStartShouldSetResponderCapture?: (event: GestureResponderEvent) => boolean;
|
|
1050
|
-
onTouchCancel?: (event: GestureResponderEvent) => void;
|
|
1051
|
-
onTouchEnd?: (event: GestureResponderEvent) => void;
|
|
1052
|
-
onTouchEndCapture?: (event: GestureResponderEvent) => void;
|
|
1053
|
-
onTouchMove?: (event: GestureResponderEvent) => void;
|
|
1054
|
-
onTouchStart?: (event: GestureResponderEvent) => void;
|
|
1055
|
-
overScrollMode?: "always" | "never" | "auto";
|
|
1056
|
-
pagingEnabled?: boolean;
|
|
1057
|
-
persistentScrollbar?: boolean;
|
|
1058
|
-
pinchGestureEnabled?: boolean;
|
|
1059
|
-
pointerEvents?: "none" | "box-none" | "box-only" | "auto";
|
|
1060
|
-
refreshControl?: ReactElement<RefreshControlProps, string | JSXElementConstructor<unknown>>;
|
|
926
|
+
refreshControl?: ReactElement | null;
|
|
1061
927
|
removeClippedSubviews?: boolean;
|
|
1062
|
-
renderToHardwareTextureAndroid?: boolean;
|
|
1063
|
-
role?: Role;
|
|
1064
|
-
screenReaderFocusable?: boolean;
|
|
1065
|
-
scrollEnabled?: boolean;
|
|
1066
928
|
scrollEventThrottle?: number;
|
|
1067
|
-
scrollIndicatorInsets?: Insets;
|
|
1068
|
-
scrollPerfTag?: string;
|
|
1069
|
-
scrollToOverflowEnabled?: boolean;
|
|
1070
|
-
scrollViewRef?: Ref<unknown>;
|
|
1071
|
-
scrollsToTop?: boolean;
|
|
1072
|
-
shouldRasterizeIOS?: boolean;
|
|
1073
929
|
showsHorizontalScrollIndicator?: boolean;
|
|
1074
930
|
showsVerticalScrollIndicator?: boolean;
|
|
1075
|
-
snapToAlignment?: "start" | "center" | "end";
|
|
1076
|
-
snapToEnd?: boolean;
|
|
1077
|
-
snapToInterval?: number;
|
|
1078
|
-
snapToOffsets?: number[];
|
|
1079
|
-
snapToStart?: boolean;
|
|
1080
|
-
stickyHeaderHiddenOnScroll?: boolean;
|
|
1081
931
|
stickyHeaderIndices?: number[];
|
|
1082
|
-
style?: StyleProp<ViewStyle
|
|
1083
|
-
tabIndex?: 0 | -1;
|
|
1084
|
-
testID?: string;
|
|
1085
|
-
tvParallaxMagnification?: number;
|
|
1086
|
-
tvParallaxShiftDistanceX?: number;
|
|
1087
|
-
tvParallaxShiftDistanceY?: number;
|
|
1088
|
-
tvParallaxTiltAngle?: number;
|
|
1089
|
-
zoomScale?: number;
|
|
932
|
+
style?: StyleProp<ViewStyle>;
|
|
1090
933
|
}
|
|
1091
934
|
|
|
1092
|
-
type ScrollViewPropsWeb = Omit<LooseScrollViewProps, "style" | "contentContainerStyle" | "onScroll" | "onLayout"> & HTMLAttributes<
|
|
935
|
+
type ScrollViewPropsWeb = Omit<LooseScrollViewProps, "style" | "contentContainerStyle" | "onScroll" | "onLayout" | "pagingEnabled" | "snapToInterval"> & Omit<HTMLAttributes<HTMLDivElement>, "onScroll" | "onLayout" | "style"> & {
|
|
1093
936
|
style?: CSSProperties;
|
|
1094
937
|
contentContainerStyle?: CSSProperties;
|
|
1095
|
-
onScroll?: (event: NativeSyntheticEvent
|
|
1096
|
-
onLayout?: (event:
|
|
1097
|
-
nativeEvent: {
|
|
1098
|
-
layout: LayoutRectangle$1;
|
|
1099
|
-
};
|
|
1100
|
-
}) => void;
|
|
938
|
+
onScroll?: (event: NativeSyntheticEvent<NativeScrollEvent>) => void;
|
|
939
|
+
onLayout?: (event: LooseLayoutChangeEvent) => void;
|
|
1101
940
|
};
|
|
1102
941
|
type LegendListPropsOverrides<ItemT, TItemType extends string | undefined> = Omit<LegendListPropsBase<ItemT, ScrollViewPropsWeb, TItemType>, "refScrollView" | "renderScrollComponent" | "ListHeaderComponentStyle" | "ListFooterComponentStyle"> & {
|
|
1103
942
|
refScrollView?: Ref<HTMLElement | ScrollViewMethods>;
|
|
1104
|
-
renderScrollComponent?: (props: ScrollViewPropsWeb) => ReactElement<ScrollViewPropsWeb> | null;
|
|
1105
943
|
ListHeaderComponentStyle?: CSSProperties | undefined;
|
|
1106
944
|
ListFooterComponentStyle?: CSSProperties | undefined;
|
|
1107
945
|
};
|
|
@@ -1129,4 +967,4 @@ declare function useSyncLayout(): () => void;
|
|
|
1129
967
|
|
|
1130
968
|
declare const LegendList: LegendListComponent;
|
|
1131
969
|
|
|
1132
|
-
export { type AlwaysRenderConfig, type BaseScrollViewProps, type ColumnWrapperStyle, type GetRenderedItem, type GetRenderedItemResult, type InitialScrollAnchor, type Insets
|
|
970
|
+
export { type AlwaysRenderConfig, type BaseScrollViewProps, type ColumnWrapperStyle, type GetRenderedItem, type GetRenderedItemResult, type InitialScrollAnchor, type Insets, type InternalState, type LayoutRectangle, LegendList, type LegendListComponent, type LegendListMetrics, type LegendListProps, type LegendListPropsBase, type LegendListRecyclingState, type LegendListRef, type LegendListRenderItemProps, type LegendListScrollerRef, type LegendListState, type MaintainScrollAtEndOptions, type MaintainVisibleContentPositionConfig, type MaintainVisibleContentPositionNormalized, type NativeScrollEvent, type NativeSyntheticEvent, type OnViewableItemsChanged, type ScrollEventTargetLike, type ScrollIndexWithOffset, type ScrollIndexWithOffsetAndContentOffset, type ScrollIndexWithOffsetPosition, type ScrollTarget, type ScrollableNodeLike, type StickyHeaderConfig, type StyleProp, type ThresholdSnapshot, type TypedForwardRef, type TypedMemo, type ViewAmountToken, type ViewStyle, type ViewToken, type ViewabilityAmountCallback, type ViewabilityCallback, type ViewabilityConfig, type ViewabilityConfigCallbackPair, type ViewabilityConfigCallbackPairs, type ViewableRange, typedForwardRef, typedMemo, useIsLastItem, useListScrollSize, useRecyclingEffect, useRecyclingState, useSyncLayout, useViewability, useViewabilityAmount };
|