Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(types): sync components types #13553

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions packages/taro-components/types/Picker.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -147,12 +147,12 @@ interface PickerTimeProps extends PickerStandardProps {
*/
value: string
/**
* 仅当 mode = time|date 时有效,表示有效时间范围的开始,字符串格式为"hh:mm"
* 仅当 mode 为 "time" 或 "date" 时有效,表示有效时间范围的开始,字符串格式为"hh:mm"
* @supported weapp, h5, rn
*/
start?: string
/**
* 仅当 mode = time|date 时有效,表示有效时间范围的结束,字符串格式为"hh:mm"
* 仅当 mode 为 "time" 或 "date" 时有效,表示有效时间范围的结束,字符串格式为"hh:mm"
* @supported weapp, h5, rn
*/
end?: string
Expand All @@ -179,12 +179,12 @@ interface PickerDateProps extends PickerStandardProps {
*/
value: string
/**
* 仅当 mode = time|date 时有效,表示有效时间范围的开始,字符串格式为"hh:mm"
* 仅当 mode 为 "time" 或 "date" 时有效,表示有效时间范围的开始,字符串格式为"YYYY-MM-DD"
* @supported weapp, h5, rn
*/
start?: string
/**
* 仅当 mode = time|date 时有效,表示有效时间范围的结束,字符串格式为"hh:mm"
* 仅当 mode 为 "time" 或 "date" 时有效,表示有效时间范围的结束,字符串格式为"YYYY-MM-DD"
* @supported weapp, h5, rn
*/
end?: string
Expand Down
42 changes: 0 additions & 42 deletions packages/taro-components/types/ScrollView.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,36 +131,6 @@ interface ScrollViewProps extends StandardProps {
* @default false
*/
enablePassive?: string
/** 渲染模式
* list - 列表模式。只会渲染在屏节点,会根据直接子节点是否在屏来按需渲染,若只有一个直接子节点则性能会退化
* custom - 自定义模式。只会渲染在屏节点,子节点可以是 sticky-section list-view grid-view 等组件
* @supported weapp
* @default 'list'
*/
type: 'list' | 'custom'
/** 是否反向滚动。一般初始滚动位置是在顶部,反向滚动则是在底部。
* @supported weapp
* @default false
*/
reverse?: boolean
/** 指定视口外渲染区域的距离,默认情况下视口外节点不渲染。指定 cache-extent 可优化滚动体验和加载速度,但会提高内存占用且影响首屏速度,可按需启用。
* @supported weapp
*/
cacheExtent?: number
/** 只 scroll-into-view 到 cacheExtent 以内的目标节点,性能更佳
* @supported weapp
* @default false
*/
scrollIntoViewWithinExtent?: boolean
/** 指定 scroll-into-view 目标节点在视口内的位置。
* start - 目标节点显示在视口开始处
* center - 目标节点显示在视口中间
* end - 目标节点显示在视口结束处
* nearest - 目标节点在就近的视口边缘显示,若节点已在视口内则不触发滚动
* @supported weapp
* @default 'start'
*/
scrollIntoViewAlignment?: 'start' | 'center' | 'end' | 'nearest'
/** 滚动到顶部/左边,会触发 scrolltoupper 事件
* @supported weapp, alipay, swan, tt, qq, jd, h5, rn
*/
Expand All @@ -173,14 +143,6 @@ interface ScrollViewProps extends StandardProps {
* @supported weapp, alipay, swan, tt, qq, jd, h5, rn
*/
onScroll?: BaseEventOrigFunction<ScrollViewProps.onScrollDetail>
/** 滚动开始事件
* @supported weapp
*/
onScrollStart?:BaseEventOrigFunction<ScrollViewProps.onScrollDetail>
/** 滚动结束事件
* @supported weapp
*/
onScrollEnd?:BaseEventOrigFunction<ScrollViewProps.onScrollDetail>
/** 自定义下拉刷新控件被下拉
* @supported weapp
*/
Expand All @@ -197,10 +159,6 @@ interface ScrollViewProps extends StandardProps {
* @supported weapp
*/
onRefresherAbort?: CommonEventFunction
/** 自定义下拉刷新即将触发刷新(拖动超过 refresher-threshold 时)的事件
* @supported weapp
*/
onRefresherWillRefresh?: CommonEventFunction
/** 滑动开始事件 (同时开启 enhanced 属性后生效)
* @supported weapp
*/
Expand Down
4 changes: 2 additions & 2 deletions packages/taro-components/types/Textarea.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ interface TextareaProps extends StandardProps, FormItemProps {
autoFocus?: boolean
/** 获取焦点
* @default false
* @supported weapp, alipay, swan, tt, qq, jd, h5, rn
* @supported weapp, alipay, swan, tt, qq, jd, rn
*/
focus?: boolean
/** 是否自动增高,设置 autoHeight 时,style.height不生效
* @default false
* @supported weapp, alipay, swan, tt, qq, jd, h5, rn
* @supported weapp, alipay, swan, tt, qq, jd, rn
*/
autoHeight?: boolean
/** 如果 Textarea 是在一个 `position:fixed` 的区域,需要显示指定属性 fixed 为 true
Expand Down
Loading