UNPKG

@ray-js/smart-ui-typings

Version:

@ray-js/smart-ui 智能小程序 UI 框架的类型声明文件

68 lines (67 loc) 1.64 kB
import { VantBaseExternalClassName, VantComponent, VantEventHandler, VantOpenTypeProps, WechatOpenType } from '../base'; export interface VantGoodsActionButtonProps extends Omit<VantOpenTypeProps, 'business-id'> { /** * 按钮文字 */ text?: string; /** * 按钮颜色,支持传入 `linear-gradient` 渐变色 */ color?: string; /** * 点击后跳转的链接地址 */ url?: string; /** * 链接跳转类型 * * @default 'navigateTo' */ 'link-type'?: 'redirectTo' | 'switchTab' | 'reLaunch'; /** * 标识符 */ id?: string; /** * 是否禁用按钮 * * @default false */ disabled?: boolean; /** * 是否显示为加载状态 * * @default false */ loading?: boolean; /** * 微信开放能力,具体支持可参考 微信官方文档 */ 'open-type'?: WechatOpenType; /** * 按钮类型 * * @default 'danger' */ type?: 'primary' | 'info' | 'warning' | 'danger'; /** * 是否为朴素按钮 * * @default false */ plain?: boolean; /** * 按钮尺寸 * * @default 'normal' */ size?: 'normal' | 'large' | 'small' | 'mini'; } export interface VantGoodsActionButtonEvents { /** * 按钮点击事件回调 */ 'bind:click': VantEventHandler; } export type VantGoodsActionButtonExternalClassName = VantBaseExternalClassName; export type VantGoodsActionButton = VantComponent<VantGoodsActionButtonProps, VantGoodsActionButtonEvents, VantGoodsActionButtonExternalClassName>;