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

fix(tt): support joinGroup button #14540

Merged
merged 5 commits into from
Sep 22, 2023
Merged
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
16 changes: 14 additions & 2 deletions packages/taro-components/types/Button.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,10 @@ interface ButtonProps extends StandardProps {
* @supported swan
*/
subscribeId?: string
/** 打开群资料卡时,传递的群号
* @supported qq
/**
* @qq 打开群资料卡时,传递的群号
* @tt 群聊 id,通过创建聊天群、查询群信息获取
* @supported qq, tt
*/
groupId?: string
/** 打开频道页面时,传递的频道号
Expand Down Expand Up @@ -169,6 +171,11 @@ interface ButtonProps extends StandardProps {
* @supported tt
*/
dataAwemeId?: string
/**
* 是否开启半屏模式
* @supported tt
*/
dataIsHalfPage?: boolean
/** 用户点击该按钮时,会返回获取到的用户信息,回调的detail数据与 Taro.getUserInfo 返回的一致
*
* 生效时机: `open-type="getUserInfo"`
Expand Down Expand Up @@ -271,6 +278,11 @@ interface ButtonProps extends StandardProps {
* @supported tt
*/
onOpenAwemeUserProfile?: CommonEventFunction
/**
* 加群后触发
* @supported tt
*/
onJoinGroup?: CommonEventFunction<{ errMsg: string; errNo: number }>
}
declare namespace ButtonProps {
/** size 的合法值 */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,10 @@ require("./taro");
bindGetPhoneNumber: _empty,
"data-channel": _empty,
"data-aweme-id": _empty,
bindOpenAwemeUserProfile: _empty
"group-id": _empty,
"data-is-half-page": _empty,
bindOpenAwemeUserProfile: _empty,
bindJoinGroup: _empty
},
Form: {
"report-submit-timeout": "0"
Expand Down
5 changes: 4 additions & 1 deletion packages/taro-tt/src/components.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@ export const components = {
bindGetPhoneNumber: _empty,
'data-channel': _empty,
'data-aweme-id': _empty,
bindOpenAwemeUserProfile: _empty
'group-id': _empty,
'data-is-half-page': _empty,
bindOpenAwemeUserProfile: _empty,
bindJoinGroup: _empty,
},
Form: {
'report-submit-timeout': '0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1776,7 +1776,10 @@ require("./runtime");
bindGetPhoneNumber: _empty,
"data-channel": _empty,
"data-aweme-id": _empty,
bindOpenAwemeUserProfile: _empty
"group-id": _empty,
"data-is-half-page": _empty,
bindOpenAwemeUserProfile: _empty,
bindJoinGroup: _empty
},
Form: {
"report-submit-timeout": "0"
Expand Down