I have:
const schema = {
type: "object",
title: "Auth.js Settings",
properties: {
providers: {
type: "array",
title: "Providers",
items: {
type: "object",
oneOf: [
{
properties: {
type: { const: "google" },
clientId: { type: "string" },
clientSecret: { type: "string" },
},
required: ["type", "clientId", "clientSecret"],
additionalProperties: false,
},
{
properties: {
type: { const: "github" },
clientId: { type: "string" },
clientSecret: { type: "string" },
},
required: ["type", "clientId", "clientSecret"],
additionalProperties: false,
},
{
properties: {
type: { const: "credentials" },
authorize: { type: "string", format: "uri" },
},
required: ["type", "authorize"],
additionalProperties: false,
},
],
},
},
},
};
Normally oneOf, material appears as tab. But I want to show it as select instead of tabs with a custom renderer with an option. How can I write a tester for this? And how can the UI Schema be?
const uiSchema = {
type: "VerticalLayout",
elements: [
{
type: "Control",
scope: "#/properties/providers",
options: { format: "select" },
},
],
};
I did it this way but the format option here is valid for array. I can’t get this option in tester. Is there a ui schema for Items? Are there any examples?