NikolaySav / nova-json-schema-field

Laravel Nova field for displaying JSON schema data
https://novapackages.com/packages/nsavinov/nova-json-schema-field
26 stars 1 forks source link

Support array of objects? #1

Open olragon opened 6 years ago

olragon commented 6 years ago

Blank field display when I used nova-json-schema-field with schema Array of objects

public function fields() {
    return [
        NovaJsonSchemaField::make('Options', $this->optionsSchema())
              ->listClass('list-reset')
    ]
}

public function optionsSchema() {
        return [
            'type' => 'array',
            'items' => [
                'type' => 'object',
                'required' => ['name'],
                'properties' => [
                    'name' => [
                        'type' => 'string'
                    ]
                ]
            ]
        ];
    }
fkraefft commented 6 years ago

Any update on this? Nice field btw.