2022-09-12 07:13:52 +00:00
|
|
|
const InplaceProps = [
|
|
|
|
{
|
2022-09-14 14:26:41 +00:00
|
|
|
name: 'active',
|
|
|
|
type: 'boolean',
|
|
|
|
default: 'false',
|
|
|
|
description: 'Whether the content is displayed or not.'
|
2022-09-12 07:13:52 +00:00
|
|
|
},
|
|
|
|
{
|
2024-04-09 14:11:00 +00:00
|
|
|
name: 'disabled',
|
2022-09-14 14:26:41 +00:00
|
|
|
type: 'boolean',
|
|
|
|
default: 'false',
|
|
|
|
description: 'When present, it specifies that the element should be disabled.'
|
2023-04-24 09:40:50 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
name: 'pt',
|
|
|
|
type: 'any',
|
|
|
|
default: 'null',
|
2023-08-01 14:01:12 +00:00
|
|
|
description: 'Used to pass attributes to DOM elements inside the component.'
|
2023-07-06 13:20:37 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
name: 'unstyled',
|
|
|
|
type: 'boolean',
|
|
|
|
default: 'false',
|
|
|
|
description: 'When enabled, it removes component related styles in the core.'
|
2022-09-12 07:13:52 +00:00
|
|
|
}
|
|
|
|
];
|
|
|
|
|
|
|
|
const InplaceEvents = [
|
|
|
|
{
|
2022-09-14 14:26:41 +00:00
|
|
|
name: 'open',
|
|
|
|
description: 'Callback to invoke when inplace is opened.',
|
2022-09-12 07:13:52 +00:00
|
|
|
arguments: [
|
|
|
|
{
|
2022-09-14 14:26:41 +00:00
|
|
|
name: 'event',
|
|
|
|
type: 'object',
|
|
|
|
description: 'Browser event'
|
2022-09-12 07:13:52 +00:00
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
2022-09-14 14:26:41 +00:00
|
|
|
name: 'close',
|
|
|
|
description: 'Callback to invoke when inplace is closed.',
|
2022-09-12 07:13:52 +00:00
|
|
|
arguments: [
|
|
|
|
{
|
2022-09-14 14:26:41 +00:00
|
|
|
name: 'event',
|
|
|
|
type: 'object',
|
|
|
|
description: 'Browser event'
|
2022-09-12 07:13:52 +00:00
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
];
|
|
|
|
|
|
|
|
const InplaceSlots = [
|
|
|
|
{
|
2022-09-14 14:26:41 +00:00
|
|
|
name: 'display',
|
2023-04-18 13:42:36 +00:00
|
|
|
description: 'Custom display template.'
|
2022-09-12 07:13:52 +00:00
|
|
|
},
|
|
|
|
{
|
2022-09-14 14:26:41 +00:00
|
|
|
name: 'content',
|
2023-04-18 13:42:36 +00:00
|
|
|
description: 'Custom content template.'
|
2022-09-12 07:13:52 +00:00
|
|
|
}
|
|
|
|
];
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
inplace: {
|
2022-09-14 14:26:41 +00:00
|
|
|
name: 'Inplace',
|
|
|
|
description: 'Inplace provides an easy to do editing and display at the same time where clicking the output displays the actual content.',
|
2022-09-12 07:13:52 +00:00
|
|
|
props: InplaceProps,
|
|
|
|
events: InplaceEvents,
|
|
|
|
slots: InplaceSlots
|
|
|
|
}
|
|
|
|
};
|