//自定义处理props的buildProps工具类 import { buildProps, definePropType } from "../../../utils/props"; import type { ExtractPropTypes, StyleValue } from "vue"; export const menuProps = buildProps({ /** * @description 皮肤颜色(默认为综合业务平台常用的蓝色 #306ef7) */ themeColor: { type: definePropType([String]), default: "#306ef7", }, /** * @description 菜单数据 */ treelists: { type: Array, }, } as const); /** * @description handleToIndex:通知跳转到首页 * @description handleMenuClick:选择菜单路由后得跳转 */ // 组件emit暴露给父组件使用的emits数组,可多个 export const menuEmits = ["handleToIndex", "handleMenuClick"]; export type MenuProps = ExtractPropTypes; export type MenuEmits = typeof menuEmits;