I have no idea what’s wrong/missing, or how else can I implement a page selector in this dialog - Using select with type: query, or even PHP generated options also doesn’t seem to work.
Okay, I’ve trailed through Vue DevTools and now have a very vague idea about what this error message is about, but I can’t properly decode how to setup the endpoints prop.
Sidenote: I managed to get the select working by studying the custom add fields plugin
Okay. I now managed to make the error go away by simply stealing the endpoint from existing page/field and it… works. I’d rather do actual proper endpoint, but have no idea if there is a documentation like “preparing custom endpoint for usage in a page field in a custom dialog”
But what’s currently bigger problem, no matter how I close the “select page” dialog (cancel or submit), my custom dialog closes as well.
After consulting on Discord, Kirby currently doesn’t support stacking dialogs, so Pages field (with its “select page” dialog) won’t work inside the custom dialog.
For others landing on this topic: use select or multiselect field (or other options like toggles, if it fits your needs)