token.d.ts 736 B

12345678910111213141516
  1. import type { OptionV2Props, SelectV2Instance, SelectV2Props } from './defaults';
  2. import type { InjectionKey, Ref } from 'vue';
  3. import type { Option } from './select.types';
  4. import type { TooltipInstance } from 'element-plus/es/components/tooltip';
  5. export interface SelectV2Context {
  6. props: SelectV2Props;
  7. expanded: Ref<boolean>;
  8. tooltipRef: Ref<TooltipInstance | undefined>;
  9. contentId: Ref<string>;
  10. onSelect: (option: Option) => void;
  11. onHover: (idx?: number) => void;
  12. onKeyboardNavigate: (direction: 'forward' | 'backward') => void;
  13. onKeyboardSelect: () => void;
  14. }
  15. export declare const selectV2InjectionKey: InjectionKey<SelectV2Context>;
  16. export type { SelectV2Instance, OptionV2Props, SelectV2Props };