<template>
  <n-options-cascader ref="options" v-model="isFocus" v-bind="{disabled, state, options, maxHeight, autoClose: false, builders, multiple}"
                      @click="onOptionSelect">
    <n-filter-refer class="n-select-cascader-filter" v-model="isFocus" v-bind="{label, state, name, values, multiple, disabled, clearable}"
                    @u-update="onReferUpdateValues"></n-filter-refer>
  </n-options-cascader>
</template>
<script>
import NOptionsCascader from '@uif/next/lib/components/options-cascader'
import NSelectFilter from '@uif/next/lib/components/select-filter'

export default {
  inheritAttrs: false,
  name: 'n-select-cascader-filter',
  extends: NSelectFilter,
  components: {
    NOptionsCascader
  },
  props: {
    // 多选
    multiple: {
      validator (value) {
        value && console.error('n-select-cascader-filter 不支持 multiple')
        return value === false
      },
      default: false
    }
  }
}
</script>
