Refactor #3889 - For SpeedDial
parent
48b066b38c
commit
aef0282979
|
@ -24,16 +24,7 @@
|
||||||
</slot>
|
</slot>
|
||||||
<ul :ref="listRef" :id="id + '_list'" class="p-speeddial-list" role="menu" @focus="onFocus" @blur="onBlur" @keydown="onKeyDown" :aria-activedescendant="focused ? focusedOptionId : undefined" tabindex="-1" v-bind="ptm('menu')">
|
<ul :ref="listRef" :id="id + '_list'" class="p-speeddial-list" role="menu" @focus="onFocus" @blur="onBlur" @keydown="onKeyDown" :aria-activedescendant="focused ? focusedOptionId : undefined" tabindex="-1" v-bind="ptm('menu')">
|
||||||
<template v-for="(item, index) of model" :key="index">
|
<template v-for="(item, index) of model" :key="index">
|
||||||
<li
|
<li v-if="isItemVisible(item)" :id="`${id}_${index}`" :aria-controls="`${id}_item`" class="p-speeddial-item" :class="itemClass(`${id}_${index}`)" :style="getItemStyle(index)" role="menuitem" v-bind="ptm('menuitem')">
|
||||||
v-if="isItemVisible(item)"
|
|
||||||
:id="`${id}_${index}`"
|
|
||||||
:aria-controls="`${id}_item`"
|
|
||||||
class="p-speeddial-item"
|
|
||||||
:class="itemClass(`${id}_${index}`)"
|
|
||||||
:style="getItemStyle(index)"
|
|
||||||
role="menuitem"
|
|
||||||
v-bind="ptm('menuitem', { activeDescendant: focused ? focusedOptionId : undefined })"
|
|
||||||
>
|
|
||||||
<template v-if="!$slots.item">
|
<template v-if="!$slots.item">
|
||||||
<a
|
<a
|
||||||
v-tooltip:[tooltipOptions]="{ value: item.label, disabled: !tooltipOptions }"
|
v-tooltip:[tooltipOptions]="{ value: item.label, disabled: !tooltipOptions }"
|
||||||
|
@ -45,7 +36,7 @@
|
||||||
:target="item.target"
|
:target="item.target"
|
||||||
@click="onItemClick($event, item)"
|
@click="onItemClick($event, item)"
|
||||||
:aria-label="item.label"
|
:aria-label="item.label"
|
||||||
v-bind="ptm('action', { activeDescendant: focused ? focusedOptionId : undefined })"
|
v-bind="ptm('action')"
|
||||||
>
|
>
|
||||||
<span v-if="item.icon" :class="['p-speeddial-action-icon', item.icon]" v-bind="ptm('actionIcon')"></span>
|
<span v-if="item.icon" :class="['p-speeddial-action-icon', item.icon]" v-bind="ptm('actionIcon')"></span>
|
||||||
</a>
|
</a>
|
||||||
|
|
Loading…
Reference in New Issue