EASYAIuniappNewUI/node_modules/@tuniao/tnui-vue3-uniapp/tokens/avatar.ts
2025-02-08 18:50:38 +08:00

18 lines
455 B
TypeScript

import type { InjectionKey } from 'vue'
import type { AvatarGroupProps } from '../components'
export type AvatarContext = {
uid: number
}
export type AvatarGroupContext = AvatarGroupProps & {
avatarItems: AvatarContext[]
addItem: (item: AvatarContext) => void
removeItem: (uid: number) => void
handleItemClick: (uid: number) => void
}
export const avatarGroupContextKey: InjectionKey<AvatarGroupContext> = Symbol(
'avatarGroupContextKey'
)