constants.ts 480 B

123456789101112131415
  1. import type { InjectionKey, ToRefs, WritableComputedRef } from 'vue'
  2. import type { CheckboxGroupProps } from './checkbox-group'
  3. type CheckboxGroupContext = {
  4. modelValue?: WritableComputedRef<any>
  5. changeEvent?: (...args: any) => any
  6. } & ToRefs<
  7. Pick<
  8. CheckboxGroupProps,
  9. 'size' | 'min' | 'max' | 'disabled' | 'validateEvent' | 'fill' | 'textColor'
  10. >
  11. >
  12. export const checkboxGroupContextKey: InjectionKey<CheckboxGroupContext> =
  13. Symbol('checkboxGroupContextKey')