Merge pull request #2728 from tugcekucukoglu/menu-spaces

Fixed #2695 - Menu, Menubar, ContextMenu, TieredMenu: Extra spacing w…
pull/2731/head
Tuğçe Küçükoğlu 2022-06-28 17:21:51 +03:00 committed by GitHub
commit d1a96c3778
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 8 deletions

View File

@ -7,13 +7,13 @@
<template v-if="!template">
<router-link v-if="item.to && !disabled(item)" :to="item.to" custom v-slot="{navigate, href, isActive, isExactActive}">
<a :href="href" @click="onItemClick($event, item, navigate)" :class="linkClass(item, {isActive, isExactActive})" v-ripple role="menuitem">
<span :class="['p-menuitem-icon', item.icon]"></span>
<span :class="['p-menuitem-icon', item.icon]" v-if="item.icon"></span>
<span class="p-menuitem-text">{{label(item)}}</span>
</a>
</router-link>
<a v-else :href="item.url" :class="linkClass(item)" :target="item.target" @click="onItemClick($event, item)" v-ripple
:aria-haspopup="item.items != null" :aria-expanded="item === activeItem" role="menuitem" :tabindex="disabled(item) ? null : '0'">
<span :class="['p-menuitem-icon', item.icon]"></span>
<span :class="['p-menuitem-icon', item.icon]" v-if="item.icon"></span>
<span class="p-menuitem-text">{{label(item)}}</span>
<span class="p-submenu-icon pi pi-angle-right" v-if="item.items"></span>
</a>

View File

@ -3,12 +3,12 @@
<template v-if="!template">
<router-link v-if="item.to && !disabled(item)" :to="item.to" custom v-slot="{navigate, href, isActive, isExactActive}">
<a :href="href" @click="onClick($event, navigate)" :class="linkClass(item, {isActive, isExactActive})" v-ripple role="menuitem">
<span :class="['p-menuitem-icon', item.icon]"></span>
<span :class="['p-menuitem-icon', item.icon]" v-if="item.icon"></span>
<span class="p-menuitem-text">{{label()}}</span>
</a>
</router-link>
<a v-else :href="item.url" :class="linkClass(item)" @click="onClick" :target="item.target" role="menuitem" :tabindex="disabled(item) ? null : '0'" v-ripple>
<span :class="['p-menuitem-icon', item.icon]"></span>
<span :class="['p-menuitem-icon', item.icon]" v-if="item.icon"></span>
<span class="p-menuitem-text">{{label()}}</span>
</a>
</template>

View File

@ -6,13 +6,13 @@
<template v-if="!template">
<router-link v-if="item.to && !disabled(item)" :to="item.to" custom v-slot="{navigate, href, isActive, isExactActive}">
<a :href="href" @click="onItemClick($event, item, navigate)" :class="linkClass(item, {isActive, isExactActive})" v-ripple @keydown="onItemKeyDown($event, item)" role="menuitem">
<span :class="['p-menuitem-icon', item.icon]"></span>
<span :class="['p-menuitem-icon', item.icon]" v-if="item.icon"></span>
<span class="p-menuitem-text">{{label(item)}}</span>
</a>
</router-link>
<a v-else :href="item.url" :class="linkClass(item)" :target="item.target" :aria-haspopup="item.items != null" :aria-expanded="item === activeItem"
@click="onItemClick($event, item)" @keydown="onItemKeyDown($event, item)" role="menuitem" :tabindex="disabled(item) ? null : '0'" v-ripple>
<span :class="['p-menuitem-icon', item.icon]"></span>
<span :class="['p-menuitem-icon', item.icon]" v-if="item.icon"></span>
<span class="p-menuitem-text">{{label(item)}}</span>
<span :class="getSubmenuIcon()" v-if="item.items"></span>
</a>

View File

@ -6,13 +6,13 @@
<template v-if="!template">
<router-link v-if="item.to && !disabled(item)" :to="item.to" custom v-slot="{navigate, href, isActive, isExactActive}">
<a :href="href" @click="onItemClick($event, item, navigate)" :class="linkClass(item, {isActive, isExactActive})" v-ripple @keydown="onItemKeyDown($event, item)" role="menuitem">
<span :class="['p-menuitem-icon', item.icon]"></span>
<span :class="['p-menuitem-icon', item.icon]" v-if="item.icon"></span>
<span class="p-menuitem-text">{{label(item)}}</span>
</a>
</router-link>
<a v-else :href="item.url" :class="linkClass(item)" :target="item.target" :aria-haspopup="item.items != null" :aria-expanded="item === activeItem"
@click="onItemClick($event, item)" @keydown="onItemKeyDown($event, item)" role="menuitem" :tabindex="disabled(item) ? null : '0'" v-ripple>
<span :class="['p-menuitem-icon', item.icon]"></span>
<span :class="['p-menuitem-icon', item.icon]" v-if="item.icon"></span>
<span class="p-menuitem-text">{{label(item)}}</span>
<span class="p-submenu-icon pi pi-angle-right" v-if="item.items"></span>
</a>