koumoul-dev / vuetify-jsonschema-form

Create beautiful and low-effort forms that output valid data. Published on npm as @koumoul/vjsf.
https://koumoul-dev.github.io/vuetify-jsonschema-form/latest/
MIT License
538 stars 154 forks source link

Vuetify props don't get passed / rendered correctly #292

Closed MagiciMan closed 2 years ago

MagiciMan commented 2 years ago

Looking at the example of using Vuetify props through X-props, the chips prop don't seem to be working :

const model = {
    chipsEnumProp: []
}

const options =  {}

const schema = {
    type: 'object',
    properties: {
        chipsEnumProp: {
            type: 'array',
            description: 'I\'m an array of strings from an enum with a bunch of additional props',
            'x-props': {
                chips: true,
                deletableChips: true,
                soloInverted: true,
                prependIcon: 'mdi-heart'
            },
            items: {
                type: 'string',
                enum: [
                    'value 1',
                    'value 2'
                ]
            }
        }
    }
}

Vue.component('VJsf', VJsf.default)

new Vue({
  el: '#app',
  vuetify: new Vuetify(),
  data: {
    model,
    options,
    schema,
    valid: null
  },
  methods: {
    logEvent(key, $event) {
      console.log('vjsf event', key, $event)
    }
  }
})

image

albanm commented 2 years ago

Yes, that is right. Duplicate of https://github.com/koumoul-dev/vuetify-jsonschema-form/issues/281