Refactor #5682
parent
2eec11b8d8
commit
4c3c2b8bf3
|
@ -59,7 +59,7 @@
|
|||
<!-- TODO: removetokenicon and removeTokenIcon deprecated since v4.0. Use chipicon slot and chipIcon prop-->
|
||||
<Chip :class="cx('chipLabel')" :label="getOptionLabel(option)" :removeIcon="chipIcon || removeTokenIcon" removable :unstyled="unstyled" @remove="removeOption($event, i)" :pt="ptm('chipLabel')">
|
||||
<template #removeicon>
|
||||
<slot :name="$slots.removetokenicon ? 'removetokenicon' : 'chipicon'" :class="cx('chipIcon')" :index="i" :removeCallback="(event) => removeOption(event, i)" />
|
||||
<slot :name="$slots.chipicon ? 'chipicon' : 'removetokenicon'" :class="cx('chipIcon')" :index="i" :removeCallback="(event) => removeOption(event, i)" />
|
||||
</template>
|
||||
</Chip>
|
||||
</slot>
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
v-bind="{ ...toggleButtonProps, ...ptm('toggler') }"
|
||||
>
|
||||
<!--TODO: togglericon deprecated since v4.0-->
|
||||
<slot :name="$slots.togglericon ? 'togglericon' : 'toggleicon'" :collapsed="d_collapsed">
|
||||
<slot :name="$slots.toggleicon ? 'toggleicon' : 'togglericon'" :collapsed="d_collapsed">
|
||||
<component :is="d_collapsed ? 'PlusIcon' : 'MinusIcon'" :class="cx('toggleIcon')" v-bind="ptm('toggleIcon')" />
|
||||
</slot>
|
||||
<slot name="legend">
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
<!-- TODO: removetokenicon and removeTokenIcon deprecated since v4.0. Use chipicon slot and chipIcon prop-->
|
||||
<Chip :class="cx('chipLabel')" :label="val" :removeIcon="chipIcon || removeTokenIcon" removable :unstyled="unstyled" @remove="removeItem($event, i)" :pt="ptm('chipLabel')">
|
||||
<template #removeicon>
|
||||
<slot :name="$slots.removetokenicon ? 'removetokenicon' : 'chipicon'" :class="cx('chipIcon')" :index="i" :removeCallback="(event) => removeItem(event, i)" />
|
||||
<slot :name="$slots.chipicon ? 'chipicon' : 'removetokenicon'" :class="cx('chipIcon')" :index="i" :removeCallback="(event) => removeItem(event, i)" />
|
||||
</template>
|
||||
</Chip>
|
||||
</slot>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<slot name="start"></slot>
|
||||
</div>
|
||||
<!--TODO: menubutton deprecated since v4.0. Use button-->
|
||||
<slot :id="id" :name="$slots.menubutton ? 'menubutton' : 'button'" :class="cx('button')" :toggleCallback="(event) => menuButtonClick(event)">
|
||||
<slot :id="id" :name="$slots.button ? 'button' : 'menubutton'" :class="cx('button')" :toggleCallback="(event) => menuButtonClick(event)">
|
||||
<a
|
||||
v-if="model && model.length > 0"
|
||||
ref="menubutton"
|
||||
|
@ -20,7 +20,7 @@
|
|||
v-bind="ptm('button')"
|
||||
>
|
||||
<!--TODO: menubuttonicon deprecated since v4.0. Use buttonicon-->
|
||||
<slot :name="$slots.menubuttonicon ? 'menubuttonicon' : 'buttonicon'">
|
||||
<slot :name="$slots.buttonicon ? 'buttonicon' : 'menubuttonicon'">
|
||||
<BarsIcon v-bind="ptm('buttonicon')" />
|
||||
</slot>
|
||||
</a>
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
<template v-if="item.items && visible(item) && !item.separator">
|
||||
<li v-if="item.items" :id="id + '_' + i" :class="[cx('submenuItem'), item.class]" role="none" v-bind="ptm('submenuItem')">
|
||||
<!--TODO: submenuheader deprecated since v4.0. Use submenuitem-->
|
||||
<slot :name="$slots.submenuheader ? 'submenuheader' : 'submenuitem'" :item="item">{{ label(item) }}</slot>
|
||||
<slot :name="$slots.submenuitem ? 'submenuitem' : 'submenuheader'" :item="item">{{ label(item) }}</slot>
|
||||
</li>
|
||||
<template v-for="(child, j) of item.items" :key="child.label + i + '_' + j">
|
||||
<PVMenuitem
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
<!-- TODO: removetokenicon and removeTokenIcon deprecated since v4.0. Use chipicon slot and chipIcon prop-->
|
||||
<Chip :class="cx('chipLabel')" :label="getLabelByValue(item)" :removeIcon="chipIcon || removeTokenIcon" removable :unstyled="unstyled" @remove="removeOption($event, item)" :pt="ptm('chipLabel')">
|
||||
<template #removeicon>
|
||||
<slot :name="$slots.removetokenicon ? 'removetokenicon' : 'chipicon'" :class="cx('chipIcon')" :item="item" :removeCallback="(event) => removeOption(event, item)" />
|
||||
<slot :name="$slots.chipicon ? 'chipicon' : 'removetokenicon'" :class="cx('chipIcon')" :item="item" :removeCallback="(event) => removeOption(event, item)" />
|
||||
</template>
|
||||
</Chip>
|
||||
</slot>
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
>
|
||||
<template #icon="slotProps">
|
||||
<!--TODO: togglericon deprecated since v4.0-->
|
||||
<slot :name="$slots.togglericon ? 'togglericon' : 'toggleicon'" :collapsed="d_collapsed">
|
||||
<slot :name="$slots.toggleicon ? 'toggleicon' : 'togglericon'" :collapsed="d_collapsed">
|
||||
<component :is="d_collapsed ? 'PlusIcon' : 'MinusIcon'" :class="slotProps.class" v-bind="ptm('toggleButton')['icon']" />
|
||||
</slot>
|
||||
</template>
|
||||
|
|
|
@ -27,11 +27,11 @@
|
|||
:unstyled="unstyled"
|
||||
/>
|
||||
<!-- TODO: hide* and show* deprecated since v4.0-->
|
||||
<slot v-if="toggleMask && unmasked" :name="$slots.hideicon ? 'hideicon' : 'maskicon'" :onClick="onMaskToggle" :toggleCallback="onMaskToggle">
|
||||
<component :is="hideIcon || maskIcon ? 'i' : 'EyeSlashIcon'" :class="[cx('maskIcon'), maskIcon || hideIcon]" @click="onMaskToggle" v-bind="ptm('maskIcon')" />
|
||||
<slot v-if="toggleMask && unmasked" :name="$slots.maskicon ? 'maskicon' : 'hideicon'" :onClick="onMaskToggle" :toggleCallback="onMaskToggle">
|
||||
<component :is="maskIcon || hideIcon ? 'i' : 'EyeSlashIcon'" :class="[cx('maskIcon'), maskIcon || hideIcon]" @click="onMaskToggle" v-bind="ptm('maskIcon')" />
|
||||
</slot>
|
||||
<slot v-if="toggleMask && !unmasked" :name="$slots.showicon ? 'showicon' : 'unmaskicon'" :onClick="onMaskToggle" :toggleCallback="onMaskToggle">
|
||||
<component :is="showIcon || unmaskIcon ? 'i' : 'EyeIcon'" :class="[cx('unmaskIcon'), unmaskIcon || showIcon]" @click="onMaskToggle" v-bind="ptm('unmaskIcon')" />
|
||||
<slot v-if="toggleMask && !unmasked" :name="$slots.unmaskicon ? 'unmaskicon' : 'showicon'" :onClick="onMaskToggle" :toggleCallback="onMaskToggle">
|
||||
<component :is="unmaskIcon || showIcon ? 'i' : 'EyeIcon'" :class="[cx('unmaskIcon'), unmaskIcon || showIcon]" @click="onMaskToggle" v-bind="ptm('unmaskIcon')" />
|
||||
</slot>
|
||||
<span class="p-hidden-accessible" aria-live="polite" v-bind="ptm('hiddenAccesible')" :data-p-hidden-accessible="true">
|
||||
{{ infoText }}
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<div v-if="filter" :class="cx('filterContainer')" v-bind="ptm('filterContainer')">
|
||||
<InputText v-model="filterValue" autocomplete="off" :class="cx('filterInput')" :placeholder="filterPlaceholder" @keydown="onFilterKeydown" v-bind="ptm('filterInput')" />
|
||||
<!--TODO: searchicon deprecated since v4.0-->
|
||||
<slot :name="$slots.searchicon ? 'searchicon' : 'filtericon'" :class="cx('filterIcon')">
|
||||
<slot :name="$slots.filtericon ? 'filtericon' : 'searchicon'" :class="cx('filterIcon')">
|
||||
<SearchIcon :class="cx('filterIcon')" v-bind="ptm('filterIcon')" />
|
||||
</slot>
|
||||
</div>
|
||||
|
|
|
@ -39,7 +39,7 @@
|
|||
</div>
|
||||
<div :class="cx('dropdown')" role="button" aria-haspopup="tree" :aria-expanded="overlayVisible" v-bind="ptm('dropdown')">
|
||||
<!-- TODO: triggericon is deprecated since v4.0 -->
|
||||
<slot :name="$slots.triggericon ? 'triggericon' : 'dropdownicon'" :class="cx('dropdownIcon')">
|
||||
<slot :name="$slots.dropdownicon ? 'dropdownicon' : 'triggericon'" :class="cx('dropdownIcon')">
|
||||
<component :is="'ChevronDownIcon'" :class="cx('dropdownIcon')" v-bind="ptm('dropdownIcon')" />
|
||||
</slot>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue