diff --git a/src/uni_modules/uview-plus/components/up-button/button.uts b/src/uni_modules/uview-plus/components/up-button/button.uts new file mode 100644 index 000000000..a3fea3952 --- /dev/null +++ b/src/uni_modules/uview-plus/components/up-button/button.uts @@ -0,0 +1,42 @@ +/* + * @Author : LQ + * @Description : + * @version : 1.0 + * @Date : 2021-08-20 16:44:21 + * @LastAuthor : LQ + * @lastTime : 2021-08-20 16:51:27 + * @FilePath : /u-view2.0/uview-ui/libs/config/props/button.js + */ +export default { + // button组件 + button: { + hairline: false, + type: 'info', + size: 'normal', + shape: 'square', + plain: false, + disabled: false, + loading: false, + loadingText: '', + loadingMode: 'spinner', + loadingSize: 15, + openType: '', + formType: '', + appParameter: '', + hoverStopPropagation: true, + lang: 'en', + sessionFrom: '', + sendMessageTitle: '', + sendMessagePath: '', + sendMessageImg: '', + showMessageCard: false, + dataName: '', + throttleTime: 0, + hoverStartTime: 0, + hoverStayTime: 200, + text: '', + icon: '', + iconColor: '', + color: '' + } +} as UTSJSONObject diff --git a/src/uni_modules/uview-plus/components/up-button/props.js b/src/uni_modules/uview-plus/components/up-button/props.js index d01f0ab2a..5ce97066e 100644 --- a/src/uni_modules/uview-plus/components/up-button/props.js +++ b/src/uni_modules/uview-plus/components/up-button/props.js @@ -1,6 +1,7 @@ import { defineMixin } from '../../libs/vue' -import defProps from '../../libs/config/props.js' -export const props = defineMixin({ +import defProps from '../../libs/config/props' + +export const propsButton = defineMixin({ props: { // 是否细边框 hairline: { diff --git a/src/uni_modules/uview-plus/components/up-button/props.uts b/src/uni_modules/uview-plus/components/up-button/props.uts new file mode 100644 index 000000000..95c63797b --- /dev/null +++ b/src/uni_modules/uview-plus/components/up-button/props.uts @@ -0,0 +1,156 @@ +import { defineMixin } from '../../libs/vue.uts' +import defProps from './button.uts' +let btnProp = defProps['button'] as UTSJSONObject + +export const propsButton = defineMixin({ + props: { + // 是否细边框 + hairline: { + type: Boolean, + default: btnProp['hairline'] + }, + // 按钮的预置样式,info,primary,error,warning,success + type: { + type: String, + default: btnProp['type'] + }, + // 按钮尺寸,large,normal,small,mini + size: { + type: String, + default: btnProp['size'] + }, + // 按钮形状,circle(两边为半圆),square(带圆角) + shape: { + type: String, + default: btnProp['shape'] + }, + // 按钮是否镂空 + plain: { + type: Boolean, + default: btnProp['plain'] + }, + // 是否禁止状态 + disabled: { + type: Boolean, + default: btnProp['disabled'] + }, + // 是否加载中 + loading: { + type: Boolean, + default: btnProp['loading'] + }, + // 加载中提示文字 + loadingText: { + type: [String], + default: btnProp['loadingText'] + }, + // 加载状态图标类型 + loadingMode: { + type: String, + default: btnProp['loadingMode'] + }, + // 加载图标大小 + loadingSize: { + type: Number, + default: btnProp['loadingSize'] + }, + // 开放能力,具体请看uniapp稳定关于button组件部分说明 + // https://uniapp.dcloud.io/component/button + openType: { + type: String, + default: btnProp['openType'] + }, + // 用于