coolink
Version:
Coocaa Coolink APP JavaScript library
146 lines (145 loc) • 5.94 kB
TypeScript
import { BasicWidget } from './Widget';
import { PageProps, AppBarProps, ContainerProps, StackViewProps, ScrollViewProps, ListViewProps, NestScrollViewProps, DrawerScrollViewProps, DragableScrollViewProps, SwipeActionsViewProps, NativeViewProps, SwiperViewProps, TextProps, IconProps, ImageProps, QrImageProps, SpinProps, RefreshProps, NoticeBarProps, ButtonProps, RadioProps, CheckboxProps, InputProps, SwitchProps, PickerProps, TabViewProps, GridViewProps, SpinningWheelProps, TurntableProps, VideoViewProps, AudioViewProps, PdfViewProps } from '../types/widget';
export declare class Page extends BasicWidget<PageProps, any> {
static invokeBeforePagePop(): Promise<boolean>;
static invokePageOnShow(contextId: string): void;
static invokePageOnHide(contextId: string): void;
static invokePageOnResume(contextId: string): void;
static invokePageOnPause(contextId: string): void;
private static getPageWithContextId;
}
export declare class AppBar extends BasicWidget<AppBarProps, any> {
private __lastTitle;
updateTitle(title: string): void;
}
export declare class Container extends BasicWidget<ContainerProps, any> {
}
export declare class StackView extends BasicWidget<StackViewProps, any> {
}
export declare class ScrollView extends BasicWidget<ScrollViewProps, any> {
scrollTo(offset: number, duration?: number): void;
}
export declare class ListView extends BasicWidget<ListViewProps, any> {
scrollTo(offset: number, duration?: number): void;
stopAsyncOperate(type: 'refresh' | 'loadMore'): void;
}
export declare class NestScrollView extends BasicWidget<NestScrollViewProps, any> {
open(): void;
close(): void;
}
export declare class DrawerScrollView extends BasicWidget<DrawerScrollViewProps, any> {
}
export declare class DragableScrollView extends BasicWidget<DragableScrollViewProps, any> {
scrollTo(offset: number, duration?: number): void;
dragPositionAnimateTo(positionType: 'initial' | 'max' | 'min'): void;
}
export declare class SwipeActionsView extends BasicWidget<SwipeActionsViewProps, any> {
openActions(): void;
closeActions(): void;
}
export declare class SwiperView extends BasicWidget<SwiperViewProps, any> {
swipeTo(index: number, duration?: number): void;
}
export declare class NativeView extends BasicWidget<NativeViewProps, any> {
refresh(params?: any): void;
destroy(params?: any): void;
invokeCustomMethod(methodName: string, methodParams?: any): void;
}
export declare class Icon extends BasicWidget<IconProps, any> {
}
export declare class Image extends BasicWidget<ImageProps, any> {
}
export declare class QrImage extends BasicWidget<QrImageProps, any> {
}
export declare class Text extends BasicWidget<TextProps, any> {
}
export declare class Spin extends BasicWidget<SpinProps, any> {
}
export declare class Refresh extends BasicWidget<RefreshProps, any> {
}
export declare class NoticeBar extends BasicWidget<NoticeBarProps, any> {
}
export declare class Button extends BasicWidget<ButtonProps, any> {
}
export declare class Radio extends BasicWidget<RadioProps, any> {
}
export declare class Switch extends BasicWidget<SwitchProps, any> {
}
export declare class Checkbox extends BasicWidget<CheckboxProps, any> {
}
export declare class Input extends BasicWidget<InputProps, any> {
setValue(value: string): void;
focus(): void;
blur(): void;
}
export declare class Picker extends BasicWidget<PickerProps, any> {
jumpTo(index: number): void;
animateTo(index: number, duration?: number): void;
}
export declare class TabView extends BasicWidget<TabViewProps, any> {
switchTo(index: number): void;
}
export declare class GridView extends BasicWidget<GridViewProps, any> {
scrollTo(offset: number, duration?: number): void;
}
export declare class VideoView extends BasicWidget<VideoViewProps, any> {
play(): void;
pause(): void;
seekTo(duration: number): void;
setVolume(volume: number): void;
}
export declare class AudioView extends BasicWidget<AudioViewProps, any> {
play(): void;
pause(): void;
seekTo(duration: number): void;
setVolume(volume: number): void;
setSourceUrl(url: string): void;
}
export declare class PdfView extends BasicWidget<PdfViewProps, any> {
openFile(filePath: String): void;
setPage(page: number): void;
setScale(centerX: number, centerY: number, scale: number, pdfViewWidth: number, pdfViewHeight: number, isTV: boolean): void;
switchTheme(): void;
getPageCount(): void;
getCurrentPage(): void;
chooseLocalFile(): void;
}
export declare class Spinningwheel extends BasicWidget<SpinningWheelProps, any> {
}
export declare class Turntable extends BasicWidget<TurntableProps, any> {
}
declare const _default: {
Page: typeof Page;
AppBar: typeof AppBar;
Container: typeof Container;
StackView: typeof StackView;
ScrollView: typeof ScrollView;
ListView: typeof ListView;
NestScrollView: typeof NestScrollView;
DrawerScrollView: typeof DrawerScrollView;
DragableScrollView: typeof DragableScrollView;
SwipeActionsView: typeof SwipeActionsView;
SwiperView: typeof SwiperView;
NativeView: typeof NativeView;
Icon: typeof Icon;
Image: typeof Image;
QrImage: typeof QrImage;
Text: typeof Text;
Spin: typeof Spin;
Refresh: typeof Refresh;
NoticeBar: typeof NoticeBar;
Button: typeof Button;
Radio: typeof Radio;
Checkbox: typeof Checkbox;
Input: typeof Input;
Switch: typeof Switch;
Picker: typeof Picker;
TabView: typeof TabView;
Spinningwheel: typeof Spinningwheel;
Turntable: typeof Turntable;
GridView: typeof GridView;
VideoView: typeof VideoView;
AudioView: typeof AudioView;
PdfView: typeof PdfView;
};
export default _default;