uni-events-helper-wx
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
1.7 KiB

3 years ago
  1. <template>
  2. <uvInput
  3. :value="value"
  4. :type="type"
  5. :fixed="fixed"
  6. :disabled="disabled"
  7. :disabledColor="disabledColor"
  8. :clearable="clearable"
  9. :password="password"
  10. :maxlength="maxlength"
  11. :placeholder="placeholder"
  12. :placeholderClass="placeholderClass"
  13. :placeholderStyle="placeholderStyle"
  14. :showWordLimit="showWordLimit"
  15. :confirmType="confirmType"
  16. :confirmHold="confirmHold"
  17. :holdKeyboard="holdKeyboard"
  18. :focus="focus"
  19. :autoBlur="autoBlur"
  20. :disableDefaultPadding="disableDefaultPadding"
  21. :cursor="cursor"
  22. :cursorSpacing="cursorSpacing"
  23. :selectionStart="selectionStart"
  24. :selectionEnd="selectionEnd"
  25. :adjustPosition="adjustPosition"
  26. :inputAlign="inputAlign"
  27. :autosize="autosize"
  28. :fontSize="fontSize"
  29. :color="color"
  30. :prefixIcon="prefixIcon"
  31. :suffixIcon="suffixIcon"
  32. :suffixIconStyle="suffixIconStyle"
  33. :prefixIconStyle="prefixIconStyle"
  34. :border="border"
  35. :readonly="readonly"
  36. :shape="shape"
  37. :customStyle="customStyle"
  38. :formatter="formatter"
  39. @focus="$emit('focus')"
  40. @blur="$emit('blur')"
  41. @keyboardheightchange="$emit('keyboardheightchange')"
  42. @change="e => $emit('change', e)"
  43. @input="e => $emit('input', e)"
  44. @clear="$emit('clear')"
  45. @click="$emit('click')"
  46. ></uvInput>
  47. </template>
  48. <script>
  49. /**
  50. * 此组件存在的理由是在nvue下u-input被uni-app官方占用了u-input在nvue中相当于input组件
  51. * 所以在nvue下取名为u--input内部其实还是u-input.vue只不过做一层中转
  52. */
  53. import uvInput from '../u-input/u-input.vue';
  54. import props from '../u-input/props.js'
  55. export default {
  56. name: 'u--input',
  57. mixins: [uni.$u.mpMixin, props, uni.$u.mixin],
  58. components: {
  59. uvInput
  60. },
  61. }
  62. </script>