xm-mobile-input.vue 609 B

1234567891011121314151617181920212223242526272829303132
  1. <template>
  2. <xm-verify-input v-model="component.attr.defaultValue" :regex="/^1[3456789]\d{9}$/" />
  3. </template>
  4. <script>
  5. import components from './_import-components/xm-mobile-input-import'
  6. export const metaInfo = {
  7. caption: '手机',
  8. component: 'a-input',
  9. icon: 'mobile',
  10. order: 100,
  11. }
  12. export const fieldProps = {
  13. dataType: 'string',
  14. attr: {
  15. regex: `^1[3456789]\\d{9}$`,
  16. regexMessage: '格式有误',
  17. },
  18. }
  19. export default {
  20. name: 'XmMobileInput',
  21. components,
  22. data() {
  23. return {}
  24. },
  25. methods: {},
  26. }
  27. </script>
  28. <style module lang="scss">
  29. @use '@/common/design' as *;
  30. </style>