UNPKG

element-plus

Version:

A Component Library for Vue 3

1 lines 1.07 kB
{"version":3,"file":"index.mjs","sources":["../../../../../packages/hooks/use-aria/index.ts"],"sourcesContent":["import { pick } from 'lodash-unified'\nimport { buildProps } from '@element-plus/utils'\n\nexport const ariaProps = buildProps({\n /**\n * @description native `aria-label` attribute\n */\n ariaLabel: String,\n /**\n * @description native `aria-orientation` attribute\n */\n ariaOrientation: {\n type: String,\n values: ['horizontal', 'vertical', 'undefined'],\n },\n /**\n * @description native `aria-controls` attribute\n */\n ariaControls: String,\n})\n\nexport const useAriaProps = <T extends keyof typeof ariaProps>(\n arias: Array<T>\n) => {\n return pick<typeof ariaProps, T>(ariaProps, arias)\n}\n"],"names":[],"mappings":";;;AAGO,MAAM,YAAY,UAAW,CAAA;AAAA,EAIlC,SAAW,EAAA,MAAA;AAAA,EAIX,eAAiB,EAAA;AAAA,IACf,IAAM,EAAA,MAAA;AAAA,IACN,MAAQ,EAAA,CAAC,YAAc,EAAA,UAAA,EAAY,WAAW,CAAA;AAAA,GAChD;AAAA,EAIA,YAAc,EAAA,MAAA;AAChB,CAAC,EAAA;AAEY,MAAA,YAAA,GAAe,CAC1B,KACG,KAAA;AACH,EAAO,OAAA,IAAA,CAA0B,WAAW,KAAK,CAAA,CAAA;AACnD;;;;"}