8000 selector无法显示placeholder,并且会返回true · Issue #2587 · airyland/vux · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
selector无法显示placeholder,并且会返回true #2587
Closed
@QiuQiongLong

Description

@QiuQiongLong

1.最近重新安装依赖,使用selector并且设置了placeholder,但是无法显示placeholder,并且selector绑定的值会返回为true,而不是options里面绑定的值 (经过测试还原到vux早期版本也无法解决)。

2.以为是自己写法的问题,重新检出官方的demo测试依旧出现,并且换机子也无法解决,麻烦解决一下,返回true这个很头疼,谢谢作者大大。

3.重新安装依赖,并且使用selector测试即可,下面是刚刚检出的官方demo测试的结果。

源码:

<template>
  <div>
    <div class="vux-demo">
      <img class="logo" src="../assets/vux_logo.png">
      <h1> </h1>
    </div>
    <group title="without title">
      <selector placeholder="请选择省份" v-model="demo02" :options="list"></selector>
    </group>

  </div>
</template>

<script>
import { Group, Cell, Selector } from 'vux'
export default {
  components: {
    Group,
    Cell,
    Selector
  },
  watch: {
    demo02(cur, old) {
      //此处selector 绑定的值会返回true
    }
  },
  data() {
    return {
      demo02: "",
      list: [{ key: 'gd', value: '广东' }, { key: 'gx', value: '广西' }],
    }
  }
}
</script>

<style>
.vux-demo {
  text-align: center;
}
.logo {
  width: 100px;
  height: 100px;
}
</style>

界面:
image

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0