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

67 lines
1.6 KiB
JavaScript
Raw Normal View History

const PanelProps = [
{
2022-09-14 14:26:41 +00:00
name: 'header',
type: 'string',
default: 'null',
description: 'Header text of the panel.'
},
{
2022-09-14 14:26:41 +00:00
name: 'toggleable',
type: 'boolean',
default: 'null',
description: 'Defines if content of panel can be expanded and collapsed.'
},
{
2022-09-14 14:26:41 +00:00
name: 'collapsed',
type: 'boolean',
default: 'null',
description: 'Defines the initial state of panel content.'
},
{
2022-09-14 14:26:41 +00:00
name: 'toggleButtonProps',
type: 'string',
default: 'null',
description: 'Uses to pass the custom value to read for the anchor inside the component.'
}
];
const PanelEvents = [
{
2022-09-14 14:26:41 +00:00
name: 'toggle',
description: 'Callback to invoke when a tab toggle.',
arguments: [
{
2022-09-14 14:26:41 +00:00
name: 'event.originalEvent',
type: 'object',
description: 'Browser event'
},
{
2022-09-14 14:26:41 +00:00
name: 'event.value',
type: 'boolean',
description: 'collapsed state as a boolean'
}
]
}
];
const PanelSlots = [
{
2022-09-14 14:26:41 +00:00
name: 'header',
description: "Custom content for the component's header"
},
{
2022-09-14 14:26:41 +00:00
name: 'icons',
description: "Custom content for the header's icon"
}
];
module.exports = {
panel: {
2022-09-14 14:26:41 +00:00
name: 'Panel',
description: 'Panel is a container with the optional content toggle feature.',
props: PanelProps,
events: PanelEvents,
slots: PanelSlots
}
};