import { AllowedComponentProps, VNodeProps } from '../common' import type { Shape, Size } from '../common' declare interface AvatarProps { // 基础属性 id?: string | number size?: Size shape?: Shape // 头像内容 url?: string title?: string name?: string // 兼容 name 属性 icon?: string // 样式控制 bgColor?: string textColor?: string fontSize?: number | string fontWeight?: number | string iconColor?: string iconSize?: number | string // 边框 border?: boolean borderColor?: string radius?: string | number // 兼容 radius 属性 // 状态指示 status?: 'online' | 'offline' | 'busy' | 'away' showStatus?: boolean online?: boolean // 兼容 online 属性 // 角标 badge?: string | number | boolean badgeDot?: boolean badgeMax?: number badgeColor?: string badgeTextColor?: string // 交互 clickable?: boolean loading?: boolean showMenuByLongpress?: boolean // 图片设置 imageMode?: 'scaleToFill' | 'aspectFit' | 'aspectFill' | 'widthFix' | 'heightFix' | 'top' | 'bottom' | 'center' | 'left' | 'right' | 'top left' | 'top right' | 'bottom left' | 'bottom right' // 自定义样式 customStyle?: Record | string } declare interface AvatarSlots { default?: never // 未来可能支持插槽 } declare interface AvatarEmits { (e: 'click', id?: string | number): void (e: 'longpress', id?: string | number): void (e: 'error', error: Error): void } declare interface _Avatar { new(): { $props: AllowedComponentProps & VNodeProps & AvatarProps $slots: AvatarSlots $emit: AvatarEmits } } export declare const Avatar: _Avatar export default Avatar export type { AvatarProps, AvatarEmits, AvatarSlots }