primevue-mirror/api-generator/components/chip.js

74 lines
1.6 KiB
JavaScript
Raw Normal View History

const ChipProps = [
{
2022-09-14 14:26:41 +00:00
name: 'label',
type: 'string',
default: 'null',
description: 'Defines the text to display.'
},
{
2022-09-14 14:26:41 +00:00
name: 'icon',
type: 'string',
default: 'null',
description: 'Defines the icon to display.'
},
{
2022-09-14 14:26:41 +00:00
name: 'image',
type: 'string',
default: 'null',
description: 'Defines the image to display.'
},
{
2022-09-14 14:26:41 +00:00
name: 'removable',
type: 'boolean',
default: 'false',
description: 'Whether to display a remove icon.'
},
{
2022-09-14 14:26:41 +00:00
name: 'removeIconClass',
type: 'string',
default: 'pi pi-times-circle',
description: 'Icon of the remove element.'
2023-04-21 13:24:22 +00:00
},
{
name: 'pt',
type: 'any',
default: 'null',
description: 'Uses to pass attributes to DOM elements inside the component.'
}
];
const ChipEvents = [
{
2022-09-14 14:26:41 +00:00
name: 'remove',
description: 'Callback to invoke when a chip is removed.',
arguments: [
{
2022-09-14 14:26:41 +00:00
name: 'event',
type: 'object',
description: 'Browser event'
}
]
}
];
const ChipSlots = [
2023-04-18 13:42:36 +00:00
{
name: 'icon',
description: 'Custom icon template of chip component.'
},
{
name: 'removeicon',
description: 'Custom remove icon template of chip component.'
}
];
module.exports = {
chip: {
2022-09-14 14:26:41 +00:00
name: 'Chip',
description: 'Chip represents entities using icons, labels and images',
props: ChipProps,
events: ChipEvents,
slots: ChipSlots
}
};