0.0.5 • Published 4 years ago
@mas.io/mas-feedback v0.0.5
安装
tnpm install --save @alipay/mas-feedback
组件介绍
行业小程序投诉建议组件,针对支付宝行业的各个不同场景进行定制化开发,满足业务需求。
API
属性 | 必填 | 参数类型 | 参数说明 | 默认值 | 示例 |
---|---|---|---|---|---|
title | 否 | String | 标题 | 反馈建议 | 反馈建议 |
maxlength | 否 | Number | 文本框最大输入字符长度 | 200 | 200 |
placeholderText | 否 | String | 文本框占位符 | 请添加问题描述(必填,至少5个汉字) | 请添加问题描述 |
showCount | 否 | Boolean | 是否显示文本框的计数 | true | true |
btnText | 否 | String | 按钮文字 | 提交 | 提交 |
onSubmit | 否 | Function | 提交时的函数 | - | - |
onInputValue | 否 | Function | 输入时的函数 | - | - |
isDisabled | 否 | Boolean | 按钮是否禁用 | false | false |
minInputLength | 否 | Number | 最少需要输入的字符串 | 10 | 5 |
在小程序中使用
{
"usingComponents": {
"mas-feedback": "@alipay/mas-feedback/es/index"
}
}
在 page.axml 中引用组件
<!-- 页面使用方式 -->
<mas-feedback
maxlength="{{maxlength}}"
minInputLength="{{minInputLength}}"
showCount="{{showCount}}"
btnText="{{btnText}}"
placeholderText="{{placeholderText}}"
title="{{title}}"
isDisabled="{{isDisabled}}"
onSubmit="onSubmit"
onInputValue="onInputValue"
/>