update scrollToItem API
This commit is contained in:
4
doric-js/lib/src/widget/list.d.ts
vendored
4
doric-js/lib/src/widget/list.d.ts
vendored
@@ -26,7 +26,9 @@ export declare class List extends Superview {
|
||||
y: number;
|
||||
}) => void;
|
||||
scrolledPosition?: number;
|
||||
scrollToItem(context: BridgeContext, pos: number, animated?: boolean): Promise<any>;
|
||||
scrollToItem(context: BridgeContext, pos: number, config?: {
|
||||
animated?: boolean;
|
||||
}): Promise<any>;
|
||||
reset(): void;
|
||||
private getItem;
|
||||
isDirty(): boolean;
|
||||
|
@@ -47,7 +47,9 @@ export class List extends Superview {
|
||||
return this.cachedViews.values();
|
||||
}
|
||||
}
|
||||
scrollToItem(context, pos, animated) {
|
||||
scrollToItem(context, pos, config) {
|
||||
var _a;
|
||||
const animated = (_a = config) === null || _a === void 0 ? void 0 : _a.animated;
|
||||
return this.nativeChannel(context, 'scrollToItem')({ pos, animated });
|
||||
}
|
||||
reset() {
|
||||
|
Reference in New Issue
Block a user