mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-09 00:42:36 +00:00
Refactor #5682 - For Paginator, Toast
This commit is contained in:
parent
4c3c2b8bf3
commit
ce2e2b7fdd
4 changed files with 122 additions and 11 deletions
15
components/lib/toast/Toast.d.ts
vendored
15
components/lib/toast/Toast.d.ts
vendored
|
@ -278,10 +278,21 @@ export interface ToastSlots {
|
|||
message: any;
|
||||
}): VNode[];
|
||||
/**
|
||||
* Custom icon template.
|
||||
* @param {Object} scope - icon slot's params.
|
||||
* @deprecated since v4.0. Use 'messageicon' slot instead.
|
||||
* Custom message icon template.
|
||||
* @param {Object} scope - message icon slot's params.
|
||||
*/
|
||||
icon(scope: {
|
||||
/**
|
||||
* Style class of the message icon
|
||||
*/
|
||||
class: any;
|
||||
}): VNode[];
|
||||
/**
|
||||
* Custom message icon template.
|
||||
* @param {Object} scope - message icon slot's params.
|
||||
*/
|
||||
messageicon(scope: {
|
||||
/**
|
||||
* Style class of the icon
|
||||
*/
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<component v-if="templates.container" :is="templates.container" :message="message" :onClose="onCloseClick" :closeCallback="onCloseClick" />
|
||||
<div v-else :class="[cx('messageContent'), message.contentStyleClass]" v-bind="ptm('messageContent')">
|
||||
<template v-if="!templates.message">
|
||||
<component :is="templates.icon ? templates.icon : iconComponent && iconComponent.name ? iconComponent : 'span'" :class="cx('messageIcon')" v-bind="ptm('messageIcon')" />
|
||||
<component :is="templates.messageicon ? templates.messageicon : templates.icon ? templates.icon : iconComponent && iconComponent.name ? iconComponent : 'span'" :class="cx('messageIcon')" v-bind="ptm('messageIcon')" />
|
||||
<div :class="cx('messageText')" v-bind="ptm('messageText')">
|
||||
<span :class="cx('summary')" v-bind="ptm('summary')">{{ message.summary }}</span>
|
||||
<div :class="cx('detail')" v-bind="ptm('detail')">{{ message.detail }}</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue