Hi,
I’m trying to create a simple button for a textarea where it bring the page selection dialog, in which i can pick a page that has a specific template.
The point is to insert these pages in a text field, style them in the textarea and display them in the page with a specific formatting.
This is the code triggered by this.command("dialog"):
You see how it puts together the actual component name, which clashes with what you are trying to do. Instead of this.command, you will have to call this.$panel.dialog.open directly yourself.
Thanks for your reply,
It brings me to finally displaying the pages-dialog and I’m now able request the pages on my website. But I’m not able to properly display their title?
site/children?select=id,title,template,uuid won’t work - that’s not the data the pages dialog needs. You will have to familiarize yourself in detail with k-pages-dialog (and in turn k-models-dialog) for the frontend and the page field for the backend side - which will lead you to the Kirby\Cms\PagePicker and Kirby\Cms\Picker classes (especially the ::toArray() methods will show what data is passed to the Vue component). You’ll likely need a custom API endpoint.