/** * 标签聚合工具函数 * 用于多选下拉组件的标签显示逻辑 */ import type { SelectOption, TagDisplayInfo } from '../types'; /** * 计算需要显示的标签和聚合信息 * @template T 选项值的类型 * @param selectedValues 当前选中的值数组 * @param options 所有选项列表 * @param maxTagCount 最多显示的标签数量 * @returns 标签显示信息 * * @example * ```tsx * const tagInfo = calculateTagDisplay(['a', 'b', 'c', 'd'], options, 2); * // 返回: * // { * // visibleTags: [option_a, option_b], * // hiddenTags: [option_c, option_d], * // hiddenCount: 2 * // } * ``` */ export declare function calculateTagDisplay(selectedValues: T[], options: SelectOption[], maxTagCount: number): TagDisplayInfo;