Skip to content

feat: new feature of miniprogram version 1.8.6 #564

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

Merged
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
Binary file modified db/TDesign.db
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ style | Object | - | CSS(Cascading Style Sheets) | N
custom-style | Object | - | CSS(Cascading Style Sheets),used to set style on virtual component | N
adjust-position | Boolean | true | \- | N
align | String | left | text align type。options: left/center/right | N
allow-input-over-max | Boolean | false | `1.8.6`。allow to continue input on value length is over `maxlength` or `maxcharacter` | N
always-embed | Boolean | false | \- | N
auto-focus | Boolean | false | \- | N
borderless | Boolean | false | input without border | N
Expand All @@ -34,7 +35,7 @@ placeholder | String | undefined | \- | N
placeholder-class | String | input-placeholder | \- | N
placeholder-style | String | - | required | Y
prefix-icon | String / Object / Slot | - | [see more ts definition](https://github.com/Tencent/tdesign-miniprogram/blob/develop/src/common/common.ts) | N
readonly | Boolean | undefined | \- | N
readonly | Boolean | undefined | `1.8.6` | N
safe-password-cert-path | String | - | \- | N
safe-password-custom-hash | String | - | \- | N
safe-password-length | Number | - | \- | N
Expand Down
3 changes: 2 additions & 1 deletion packages/products/tdesign-miniprogram/src/input/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ style | Object | - | 样式 | N
custom-style | Object | - | 样式,一般用于开启虚拟化组件节点场景 | N
adjust-position | Boolean | true | 键盘弹起时,是否自动上推页面 | N
align | String | left | 文本内容位置,居左/居中/居右。可选项:left/center/right | N
allow-input-over-max | Boolean | false | `1.8.6`。超出 `maxlength` 或 `maxcharacter` 之后是否允许继续输入 | N
always-embed | Boolean | false | 强制 input 处于同层状态,默认 focus 时 input 会切到非同层状态 (仅在 iOS 下生效) | N
auto-focus | Boolean | false | (即将废弃,请直接使用 focus )自动聚焦,拉起键盘 | N
borderless | Boolean | false | 是否开启无边框模式 | N
Expand All @@ -34,7 +35,7 @@ placeholder | String | undefined | 占位符 | N
placeholder-class | String | input-placeholder | 指定 placeholder 的样式类 | N
placeholder-style | String | - | 必需。指定 placeholder 的样式 | Y
prefix-icon | String / Object / Slot | - | 组件前置图标。值为字符串表示图标名称,值为 `Object` 类型,表示透传至 `icon`。[通用类型定义](https://github.com/Tencent/tdesign-miniprogram/blob/develop/src/common/common.ts) | N
readonly | Boolean | undefined | 只读状态 | N
readonly | Boolean | undefined | `1.8.6`。只读状态 | N
safe-password-cert-path | String | - | 安全键盘加密公钥的路径,只支持包内路径 | N
safe-password-custom-hash | String | - | 安全键盘计算 hash 的算法表达式,如 `md5(sha1('foo' + sha256(sm3(password + 'bar'))))` | N
safe-password-length | Number | - | 安全键盘输入密码长度 | N
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ max-content-row | Number | 5 | \- | N
max-label-row | Number | 3 | \- | N
name | String | - | \- | N
placement | String | - | options: left/right | N
readonly | Boolean | undefined | \- | N
readonly | Boolean | undefined | `1.8.6` | N
value | String / Number / Boolean | false | Typescript:`T` `type RadioValue = string \| number \| boolean`。[see more ts definition](https://github.com/Tencent/tdesign-miniprogram/tree/develop/src/radio/type.ts) | N

### Radio Events
Expand Down Expand Up @@ -55,7 +55,7 @@ keys | Object | - | Typescript:`KeysType`。[see more ts definition](https://g
name | String | - | \- | N
options | Array | - | Typescript:`Array<RadioOption>` `type RadioOption = string \| number \| RadioOptionObj` `interface RadioOptionObj { label?: string; value?: string \| number; readonly?: boolean; disabled?: boolean; allowUncheck?: boolean; }`。[see more ts definition](https://github.com/Tencent/tdesign-miniprogram/tree/develop/src/radio-group/type.ts) | N
placement | String | left | options: left/right | N
readonly | Boolean | undefined | \- | N
readonly | Boolean | undefined | `1.8.6` | N
value | String / Number / Boolean | - | Typescript:`T` `type RadioValue = string \| number \| boolean`。[see more ts definition](https://github.com/Tencent/tdesign-miniprogram/tree/develop/src/radio-group/type.ts) | N
default-value | String / Number / Boolean | undefined | uncontrolled property。Typescript:`T` `type RadioValue = string \| number \| boolean`。[see more ts definition](https://github.com/Tencent/tdesign-miniprogram/tree/develop/src/radio-group/type.ts) | N

Expand Down
4 changes: 2 additions & 2 deletions packages/products/tdesign-miniprogram/src/radio/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ max-content-row | Number | 5 | 内容最大行数限制 | N
max-label-row | Number | 3 | 主文案最大行数限制 | N
name | String | - | HTML 元素原生属性 | N
placement | String | - | 复选框和内容相对位置。优先级高于 RadioGroup.placement。Radio 单独存在时,默认值为 left。如果父组件存在 RadioGroup,默认值便由 RadioGroup.placement 决定。可选项:left/right | N
readonly | Boolean | undefined | 只读状态 | N
readonly | Boolean | undefined | `1.8.6`。只读状态 | N
value | String / Number / Boolean | false | 单选按钮的值。TS 类型:`T` `type RadioValue = string \| number \| boolean`。[详细类型定义](https://github.com/Tencent/tdesign-miniprogram/tree/develop/src/radio/type.ts) | N

### Radio Events
Expand Down Expand Up @@ -55,7 +55,7 @@ keys | Object | - | 用来定义 value / label / disabled 在 `options` 中对
name | String | - | HTML 元素原生属性 | N
options | Array | - | 单选组件按钮形式。RadioOption 数据类型为 string 或 number 时,表示 label 和 value 值相同。TS 类型:`Array<RadioOption>` `type RadioOption = string \| number \| RadioOptionObj` `interface RadioOptionObj { label?: string; value?: string \| number; readonly?: boolean; disabled?: boolean; allowUncheck?: boolean; }`。[详细类型定义](https://github.com/Tencent/tdesign-miniprogram/tree/develop/src/radio-group/type.ts) | N
placement | String | left | 复选框和内容相对位置。优先级低于 Radio.placement。可选项:left/right | N
readonly | Boolean | undefined | 只读状态 | N
readonly | Boolean | undefined | `1.8.6`。只读状态 | N
value | String / Number / Boolean | - | 选中的值。TS 类型:`T` `type RadioValue = string \| number \| boolean`。[详细类型定义](https://github.com/Tencent/tdesign-miniprogram/tree/develop/src/radio-group/type.ts) | N
default-value | String / Number / Boolean | undefined | 选中的值。非受控属性。TS 类型:`T` `type RadioValue = string \| number \| boolean`。[详细类型定义](https://github.com/Tencent/tdesign-miniprogram/tree/develop/src/radio-group/type.ts) | N

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
:: BASE_DOC ::

## API

### Textarea Props

name | type | default | description | required
-- | -- | -- | -- | --
style | Object | - | CSS(Cascading Style Sheets) | N
custom-style | Object | - | CSS(Cascading Style Sheets),used to set style on virtual component | N
adjust-position | Boolean | true | \- | N
allow-input-over-max | Boolean | false | \- | N
allow-input-over-max | Boolean | false | `1.8.6` | N
autofocus | Boolean | false | \- | N
autosize | Boolean / Object | false | Typescript:`boolean \| { maxHeight?: number, minHeight?: number }` | N
bordered | Boolean | false | \- | N
Expand All @@ -28,7 +29,7 @@ maxlength | Number | -1 | \- | N
placeholder | String | undefined | \- | N
placeholder-class | String | textarea-placeholder | \- | N
placeholder-style | String | - | \- | N
readonly | Boolean | undefined | \- | N
readonly | Boolean | undefined | `1.8.6` | N
selection-end | Number | -1 | \- | N
selection-start | Number | -1 | \- | N
show-confirm-bar | Boolean | true | \- | N
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
:: BASE_DOC ::

## API

### Textarea Props

名称 | 类型 | 默认值 | 描述 | 必传
-- | -- | -- | -- | --
style | Object | - | 样式 | N
custom-style | Object | - | 样式,一般用于开启虚拟化组件节点场景 | N
adjust-position | Boolean | true | 键盘弹起时,是否自动上推页面 | N
allow-input-over-max | Boolean | false | 超出maxlength或maxcharacter之后是否还允许输入 | N
allow-input-over-max | Boolean | false | `1.8.6`。超出maxlength或maxcharacter之后是否还允许输入 | N
autofocus | Boolean | false | 自动聚焦,拉起键盘 | N
autosize | Boolean / Object | false | 是否自动增高,值为 true 时,style.height 不生效。支持传入对象,如 { maxHeight: 120, minHeight: 20 }。TS 类型:`boolean \| { maxHeight?: number, minHeight?: number }` | N
bordered | Boolean | false | 是否显示外边框 | N
Expand All @@ -28,7 +29,7 @@ maxlength | Number | -1 | 用户最多可以输入的字符个数,值为 -1
placeholder | String | undefined | 占位符 | N
placeholder-class | String | textarea-placeholder | 指定 placeholder 的样式类,目前仅支持color,font-size和font-weight | N
placeholder-style | String | - | 指定 placeholder 的样式,目前仅支持 color ,font-size和font-weight | N
readonly | Boolean | undefined | 只读状态 | N
readonly | Boolean | undefined | `1.8.6`。只读状态 | N
selection-end | Number | -1 | 光标结束位置,自动聚集时有效,需与 selection-start 搭配使用 | N
selection-start | Number | -1 | 光标起始位置,自动聚集时有效,需与 selection-end 搭配使用 | N
show-confirm-bar | Boolean | true | 是否显示键盘上方带有”完成“按钮那一栏 | N
Expand Down
18 changes: 10 additions & 8 deletions packages/scripts/api.json
Original file line number Diff line number Diff line change
Expand Up @@ -63968,7 +63968,8 @@
"4",
"8",
"16",
"32"
"32",
"64"
],
"component": "Input",
"field_category": 1,
Expand All @@ -63991,7 +63992,7 @@
"html_attribute": 0,
"trigger_elements": "",
"deprecated": 0,
"version": "",
"version": "{ \"Miniprogram\": \"1.8.6\" }",
"test_description": "{\"PC\":{\"event\":[{\"props\":{\"value\":\"Hello\",\"maxlength\":5},\"expect\":[{\"trigger\":\"simulateInputChange('input', \\\"Hello TDesign\\\")\",\"exist\":[{\"input\":{\"attribute\":{\"value\":\"Hello\"}}}]}]}]}}",
"support_default_value": 0,
"field_category_text": "Props",
Expand All @@ -64001,7 +64002,8 @@
"Angular(PC)",
"Vue(Mobile)",
"React(Mobile)",
"Angular(Mobile)"
"Angular(Mobile)",
"Miniprogram"
],
"field_type_text": [
"Boolean"
Expand Down Expand Up @@ -65506,7 +65508,7 @@
"html_attribute": 0,
"trigger_elements": "",
"deprecated": 0,
"version": null,
"version": "{ \"Miniprogram\": \"1.8.6\" }",
"test_description": "{\"PC\":{\"className\":\"t-is-readonly\",\"classNameDom\":\".t-input\"}}",
"support_default_value": 0,
"field_category_text": "Props",
Expand Down Expand Up @@ -89697,7 +89699,7 @@
"html_attribute": 0,
"trigger_elements": "",
"deprecated": 0,
"version": "",
"version": "{ \"Miniprogram\": \"1.8.6\" }",
"test_description": null,
"support_default_value": 0,
"field_category_text": "Props",
Expand Down Expand Up @@ -90737,7 +90739,7 @@
"html_attribute": 0,
"trigger_elements": "",
"deprecated": 0,
"version": "",
"version": "{ \"Miniprogram\": \"1.8.6\" }",
"test_description": null,
"support_default_value": 0,
"field_category_text": "Props",
Expand Down Expand Up @@ -120803,7 +120805,7 @@
"html_attribute": 0,
"trigger_elements": "",
"deprecated": 0,
"version": "",
"version": "{ \"Miniprogram\": \"1.8.6\" }",
"test_description": null,
"support_default_value": 0,
"field_category_text": "Props",
Expand Down Expand Up @@ -121811,7 +121813,7 @@
"html_attribute": 0,
"trigger_elements": "",
"deprecated": 0,
"version": null,
"version": "{ \"Miniprogram\": \"1.8.6\" }",
"test_description": null,
"support_default_value": 0,
"field_category_text": "Props",
Expand Down