import type { CSSProperties, Component, SetupContext } from 'vue'; /** * 只读属性改为可读 */ export type Mutable = { -readonly [P in keyof T]: T[P]; }; /** * 样式值 */ export type StyleValue = Partial; /** * 样式多个值 */ export type StyleValues = StyleValue | Array; /** * 类名值 */ export type ClassValue = string | Record; /** * 类名多个值 */ export type ClassValues = ClassValue | Array; /** * 组件属性 */ export type ComponentProps = Mutable> & { /** 类名 */ class?: ClassValues; /** 样式 */ style?: StyleValues; }; /** * 组件名或组件 */ export type UserComponent = string | Component; /** * 组件事件触发器 */ export type Emitter = SetupContext['emit'];