mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-05-20 21:39:15 +08:00
feat(Popup): add role and tabindex for a11y (#10894)
* feat(Popup): add role and tabindex for a11y * Update Popup.tsx Co-authored-by: neverland <jait.chen@foxmail.com>
This commit is contained in:
parent
b117e21dc4
commit
ed5ea225ca
@ -144,6 +144,8 @@ export default defineComponent({
|
||||
zIndex={zIndex.value}
|
||||
duration={props.duration}
|
||||
customStyle={props.overlayStyle}
|
||||
role={props.closeOnClickOverlay ? 'button' : undefined}
|
||||
tabindex={props.closeOnClickOverlay ? 0 : undefined}
|
||||
onClick={onClickOverlay}
|
||||
/>
|
||||
);
|
||||
@ -185,6 +187,8 @@ export default defineComponent({
|
||||
v-show={props.show}
|
||||
ref={popupRef}
|
||||
style={style.value}
|
||||
role="dialog"
|
||||
tabindex={0}
|
||||
class={[
|
||||
bem({
|
||||
round,
|
||||
|
Loading…
x
Reference in New Issue
Block a user