I just wrote it down in the simple version without single file components. You can totally use it like this:
import MyDrawer from "./MyDrawer.vue";
panel.plugin("my/drawer", {
components: {
"k-my-drawer": MyDrawer
},
});
and then MyDrawer.vue would look like this:
<template>
<k-drawer
class="k-my-drawer"
v-bind="$props"
@cancel="$emit('cancel', $event)"
@crumb="$emit('crumb', $event)"
@input="$emit('input', $event)"
@submit="$emit('submit', $event)"
@tab="$emit('tab', $event)"
>
{{ message }}
</k-drawer>
</template>
<script>
export default {
extends: "k-drawer",
props: {
message: String
}
};
</script>
If you already worked with a separate drawer component, there should not be too much work involved to refactor it.